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 logstash system index APIs #53350

Merged
merged 33 commits into from
Sep 14, 2020

Conversation

jaymode
Copy link
Member

@jaymode jaymode commented Mar 10, 2020

This commit adds REST apis for logstash and its system index, .logstash, which is used to store pipelines for central management. The module adds new endpoints that enable CRUD operations
on the pipelines stored in the index.

@jaymode jaymode added WIP :Core/Infra/Core Core issues without another label labels Mar 10, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (:Core/Infra/Core)

@jaymode jaymode changed the title Add logstash system index module Add logstash system index APIs Mar 10, 2020
Copy link
Contributor

@gwbrown gwbrown left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good overall, left a few comments about tweaks I think we should make.

mGetResponse -> listener.onResponse(
new GetPipelineResponse(
Arrays.stream(mGetResponse.getResponses())
.filter(itemResponse -> itemResponse.isFailed() == false)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure what to do instead, but if some of the GETs fail, do we really just want to silently swallow that? Should we at least log something here?

@bpintea bpintea added v7.8.0 and removed v7.7.0 labels Mar 25, 2020
@rjernst rjernst added the Team:Core/Infra Meta label for core/infra team label May 4, 2020
@williamrandolph
Copy link
Contributor

@elasticmachine Please run elasticsearch-ci/2

@jaymode jaymode mentioned this pull request Aug 25, 2020
23 tasks
Copy link
Contributor

@gwbrown gwbrown left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a few very minor comments, but otherwise LGTM. No need for another round of review after addressing my comments here.

@williamrandolph williamrandolph merged commit fb7471b into elastic:master Sep 14, 2020
williamrandolph added a commit to williamrandolph/elasticsearch that referenced this pull request Sep 14, 2020
We want Logstash indices to be system indices, but the logstash
service will still need to be able to manage its indices. This PR
adds special system index APIs to the logstash plugin so that
logstash can manage its pipelines without direct access to the
underlying indices.

* Add logstash module with dedicated logstash APIs
* merge with x-pack plugin
* add system index access allowance
* Break out serialization tests into distinct classes
* Log failures for partial multiget failure
* Move LogstashSystemIndexIT to javaRestTest task

Co-authored-by: William Brafford <william.brafford@elastic.co>
williamrandolph added a commit that referenced this pull request Sep 15, 2020
We want Logstash indices to be system indices, but the logstash
service will still need to be able to manage its indices. This PR
adds special system index APIs to the logstash plugin so that
logstash can manage its pipelines without direct access to the
underlying indices.

* Add logstash module with dedicated logstash APIs
* merge with x-pack plugin
* add system index access allowance
* Break out serialization tests into distinct classes
* Log failures for partial multiget failure
* Move LogstashSystemIndexIT to javaRestTest task

Co-authored-by: William Brafford <william.brafford@elastic.co>

Co-authored-by: Jay Modi <jaymode@users.noreply.github.com>
@jaymode jaymode deleted the logstash_system_index_plugin branch September 18, 2020 18:20
jaymode added a commit to jaymode/kibana that referenced this pull request Oct 13, 2020
This change updates the logstash pipeline management plugin to use
pipeline management APIs in Elasticsearch rather than directly
accessing the .logstash index. In Elasticsearch 8.0, direct access to
system indices will no longer be allowed when using standard APIs.
Given this change, a new set of APIs has been created specifically for
the management of Logstash pipelines and this change makes use of the
APIs.

Relates elastic/elasticsearch#53350
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/Core Core issues without another label >enhancement Team:Core/Infra Meta label for core/infra team v7.10.0 v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants