Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use less report cache SQL when adding results (backport #1618) #1619

Merged
merged 7 commits into from
Jul 8, 2021

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jul 7, 2021

This is an automatic backport of pull request #1618 done by Mergify.
Cherry-pick of 6d1797a has failed:

On branch mergify/bp/gvmd-21.04/pr-1618
Your branch is up to date with 'origin/gvmd-21.04'.

You are currently cherry-picking commit 6d1797a86.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   src/manage.c
	modified:   src/manage.h

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   src/manage_sql.c

To fix up this pull request, you can check it out locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/


Mergify commands and options

More conditions and actions can be found in the documentation.

You can also trigger Mergify actions by commenting on this pull request:

  • @Mergifyio refresh will re-evaluate the rules
  • @Mergifyio rebase will rebase this PR on its base branch
  • @Mergifyio update will merge the base branch into this PR
  • @Mergifyio backport <destination> will backport this PR on <destination> branch

Additionally, on Mergify dashboard you can:

  • look at your merge queues
  • generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.io/

When multiple results are added when handling an OSP get_scan response
or a host in a CVE scan, only one SQL statement each is run to update
the report and owner of the results and to update the end times of the
report_counts cache of the report.

This addresses AP-1495.

(cherry picked from commit 6d1797a)

# Conflicts:
#	src/manage_sql.c
@mergify mergify bot requested a review from a team as a code owner July 7, 2021 10:42
@mergify mergify bot added the conflicts This backport pull request has merge conflicts that need to be resolved label Jul 7, 2021
The parse_osp_report function did not use has_results before and there
is no modification_time to update in 21.04 and before.
@timopollmeier timopollmeier added conflicts-resolved This backport pull request had merge conflicts that have been resolved and removed conflicts This backport pull request has merge conflicts that need to be resolved labels Jul 7, 2021
@bjoernricks bjoernricks enabled auto-merge July 8, 2021 07:17
@bjoernricks bjoernricks merged commit 332b31b into gvmd-21.04 Jul 8, 2021
@bjoernricks bjoernricks deleted the mergify/bp/gvmd-21.04/pr-1618 branch July 8, 2021 07:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
conflicts-resolved This backport pull request had merge conflicts that have been resolved
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants