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

[Ingest Manager] Allow to filter agent list by the package they are running #69686

Closed
nchaulet opened this issue Jun 23, 2020 · 8 comments · Fixed by #69731
Closed

[Ingest Manager] Allow to filter agent list by the package they are running #69686

nchaulet opened this issue Jun 23, 2020 · 8 comments · Fixed by #69731
Assignees
Labels
Team:Fleet Team label for Observability Data Collection Fleet team v7.9.0 v8.0.0

Comments

@nchaulet
Copy link
Member

nchaulet commented Jun 23, 2020

Description

We want to allow users, and other plugins (endpoint) to filter agent by the packages they are running.

Implementation

We can populate a field packages: string[] when the agent ack for a config change. Users will be able to filter agents with a kuery like fleet-agents.packages:endpoint

cc @nnamdifrankie

@nchaulet nchaulet added v8.0.0 v7.9.0 Team:Fleet Team label for Observability Data Collection Fleet team Ingest Management:beta1 labels Jun 23, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/ingest-management (Team:Ingest Management)

@nchaulet nchaulet self-assigned this Jun 23, 2020
@nnamdifrankie
Copy link
Contributor

This will work, we will have another ticket for status changes.

@nnamdifrankie
Copy link
Contributor

@ruflin
Copy link
Member

ruflin commented Jun 24, 2020

Should this information be per agent or per config? We know on the config level for which packages it contains configs. Do we really need to duplicate the data? I understand that the query is run agains the agent but this could forward the request to the config object. Issue with that is perhaps speed?

@jen-huang
Copy link
Contributor

++ to the above comment. The PR (#69731) implements this in such a way that package information is written to the agent saved object when the agent acknowledges a config change. If a package was added to an agent config but the agent has not yet picked up the change, the results of a query for configs that use that package vs. a query for agents that use that package will differ.

Personally I'd like to avoid writing to the agent saved object as it's yet another piece of information we need to keep in sync, but maybe knowing what is actually running on the agent vs what should be running on the agent was an important distinction here?

If it isn't, we can expose another service/endpoint that queries packages against agent configs and returns agents that are using those matching configs.

@nnamdifrankie
Copy link
Contributor

but maybe knowing what is actually running on the agent vs what should be running on the agent was an important distinction here

I think it is preferable to know what is actually running because that is more likely to have corresponding event history inside in metadata index. i.e. the agent may have also transmitted some data. The downside of the "should be running" is waste of processing events that may not produce any work on the endpoint side.

@nnamdifrankie
Copy link
Contributor

Also if you don't mind me asking which approach is a larger effort, hopefully the running approach. I am asking so we can gauge how we are tracking for 7.9 on delivering the services.

@nchaulet
Copy link
Member Author

@ruflin @jen-huang I think endpoint want to know what is currently running on one agent, (this will allow to detect when endpoint is added/removed). Also from an end-user perspective I think it's a nice feature too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team:Fleet Team label for Observability Data Collection Fleet team v7.9.0 v8.0.0
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants