-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[ResponseOps][Alerting] Optimize the scheduling of rule actions so it can happen in bulk #137781
[ResponseOps][Alerting] Optimize the scheduling of rule actions so it can happen in bulk #137781
Conversation
@elasticmachine merge upstream |
…oakalexi/kibana into alerting/schedule-rule-actions-in-bulk
@elasticmachine merge upstream |
…oakalexi/kibana into alerting/schedule-rule-actions-in-bulk
…oakalexi/kibana into alerting/schedule-rule-actions-in-bulk
Pinging @elastic/response-ops (Team:ResponseOps) |
@elasticmachine merge upstream |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some initial comments after a first pass :)
@elasticmachine merge upstream |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left a few questions but overall the code is looking good and looking forward to this optimization!
Co-authored-by: Mike Côté <mikecote@users.noreply.github.com>
Co-authored-by: Mike Côté <mikecote@users.noreply.github.com>
…oakalexi/kibana into alerting/schedule-rule-actions-in-bulk
@elasticmachine merge upstream |
…oakalexi/kibana into alerting/schedule-rule-actions-in-bulk
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes LGTM! Can't wait for this optimization!
Feel free to create a follow up issue to remove the code around enqueueExecution (the non-bulk one) if the code won't be used anymore.
Thanks for reviewing! There is a route that uses |
Ah, good catch. Let's leave it as is then :-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Verified actions are being bulk scheduled 🎉
Left some minor comments but overall looks great!
x-pack/plugins/actions/server/authorization/get_authorization_mode_by_source.ts
Outdated
Show resolved
Hide resolved
x-pack/plugins/actions/server/authorization/get_authorization_mode_by_source.test.ts
Show resolved
Hide resolved
@elasticmachine merge upstream |
@elasticmachine merge upstream |
💚 Build Succeeded
Metrics [docs]
History
To update your PR or re-run it, just comment with: |
… can happen in bulk (elastic#137781) * Adding bulk scheduler * Updating bulk schedule * Fixing failing tests * Fixing test * Adding bulk schedule tests * Cleaning up enqueue function * Using bulk getConnectors * Removing empty line * Update x-pack/plugins/actions/server/create_execute_function.ts Co-authored-by: Mike Côté <mikecote@users.noreply.github.com> * Update x-pack/plugins/actions/server/create_execute_function.ts Co-authored-by: Mike Côté <mikecote@users.noreply.github.com> * Cleaning up auth * Fixing test failure * Updating bulk auth changes * Fixed track change * Fixing test failures * Addressing pr comments Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Mike Côté <mikecote@users.noreply.github.com>
Resolves #126511
Summary
We wanted to leverage bulk calls to schedule rule actions.
Checklist
To verify