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

Add mappings on .fleet-policies index to filter on data.outputs to invalidate remote API keys #3121

Open
2 tasks
juliaElastic opened this issue Nov 23, 2023 · 0 comments

Comments

@juliaElastic
Copy link
Contributor

Related to elastic/kibana#104986
Follow up after #3051 (comment)

Currently data.outputs in .fleet-policies is not mapped, so we can't use ES query to find a remote output config after it is removed from an agent/agent policy. We need the config to invalidate remote API keys that are not used anymore.

Currently the logic looks up the most recent policy revisions and loops though them to find the remote output. This is not efficient and might not return the output config.

To solve this:

  • Add ES mapping for data.outputs, to be able to search on a remote output ID
    • We should check if changing the mapping doesn't break existing clusters when migrating to a new version. Alternatively a new field name could be used for the new mapping.
 "data": {
          "enabled": false,
          "type": "object"
        },
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant