-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Move async task maintenance service to core plugin #57700
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
Move async task maintenance service to core plugin #57700
Conversation
The async task task maintenance service is used by both async search plugin as well as EQL plugin. So it needs to reside in the core. Relates to elastic#49638
|
Pinging @elastic/es-search (:Search/Search) |
|
Pinging @elastic/es-ql (:Query Languages/EQL) |
jimczi
left a comment
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.
I left one comment
| components.add(getLicenseService()); | ||
| components.add(getLicenseState()); | ||
|
|
||
| if (DiscoveryNode.isDataNode(environment.settings())) { |
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.
This makes me wonder if we should make the index a system index first ? This way, we could start the maintenance service in the system index plugin. I don't think it will cause issue to move the index into a system index since we have all the protection in place with the async search user ?
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.
Do you want me to convert AsyncSearch plugin into SystemIndexPlugin or should I create a separate "Async" plugin for that?
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.
I think we can have a dedicated plugin since the goal is to start the service for all users of the index ?
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.
👍
costin
left a comment
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.
A PR that removes code while preserving functionality? 👍
|
I added registration of system index and I also tried to move move some pieces into async plugin but it causes quite a bit of dependencies issues. We can try to move things around, but it seems to be a bigger effort and I would prefer to merge this branch first, since its prolonged maintenance takes time and increases chances of missing changes while resolving conflicts. |
I think we can restrain the async plugin to declare the system index and to start the maintenance service. It shouldn't be more than that imo. This way we can avoid starting the service in XPackPlugin and the maintenance service code can stay in x-pack core. WDYT ? |
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, I'd rename AsyncPlugin into AsyncIndexPlugin or something along those lines but no strong feeling here. Thanks for iterating on this!
|
@elasticsearchmachine run elasticsearch-ci/2 |
The async task task maintenance service is used by both async search plugin
as well as EQL plugin. So it needs to reside in the core.
Relates to #49638