-
Notifications
You must be signed in to change notification settings - Fork 25.3k
Change default value of action.destructive_requires_name
to True.
#66908
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
Change default value of action.destructive_requires_name
to True.
#66908
Conversation
Pinging @elastic/es-core-infra (Team:Core/Infra) |
@YashJipkate Please check references of this setting in the docs and other places like for example: |
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.
@matriv There are some changes I made to the doc. Please let me know if you find any issues.
I think we should also change in |
@javanna Could you please take a look as well? |
I too thought of rephrasing them at first, but they didn't say anything about 'changing' the setting to Although I'm open to suggestions on how to phrase it even better. |
jenkins test this please |
@YashJipkate I quickly looked and I think that our integration tests rely on deleting all indices without specifying their names. This is done before every single test, which explains why every single integration test fails ;) |
Separate from the tests, I have two comments:
|
action.destructive_requires_name
to True.
@rjernst Done. |
In that case, could you please guide me as to what can be done to resolve this? |
@rjernst I was wondering the same about this change in behaviour. I agree it should be done in a major. I don't think I will get to properly review this PR, would you mind finding somebody to help moving this forward please? |
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.
In order to fix the tests, we now need to set action.destructive_requires_name
cluster to false for our test clusters. It looks to me like the easiest place to do that is in the code for the test cluster setup, in the file buildSrc/src/main/java/org/elasticsearch/gradle/testclusters/ElasticsearchNode.java
. Specifically, I added:
baseConfig.put("action.destructive_requires_name", "false");
...after line 1187 of that file, and that let some of the failing integration tests pass.
I'm not sure if this will fix everything, so we may have to iterate a little bit to allow wildcard deletions in every place where the tests expect them.
I requested some wording changes in other comments and meant for those requests to be part of this review.
Thank you for working with us on this PR!
@williamrandolph I've done the changes requested by you. Also, can you start the Jenkins here since the tests are being flaky on my PC (also takes too long and freezes the system, times out), as it isn't running automatically for the subsequent pushes on this PR. Or is there any other way I can carry out the tests? |
@spalger I have tried a couple of versions of trying to reproduce this with and without other indices or hidden indices and can't get the warning in the way you reported it. Is there anything else you can provide to help me reproduce it?
|
I'm running a master snapshot built by Kibana's ES Snapshot mechanism, which we use to allow tracking master without breaking CI when breaking changes are merged into ES. The snapshot can be downloaded from https://storage.googleapis.com/kibana-ci-es-snapshots-daily/8.0.0/archives/20210124-194645_63c85ff3e84/elasticsearch-8.0.0-SNAPSHOT-darwin-x86_64.tar.gz We are currently running ES with security enabled, which maybe has something to do with it, and the CLI options: I can reproduce the issue with a single request:
|
@spalger Thanks for the additional information and clean reproduction line! It looks like having security enabled makes the difference. I've reproduced the issue on the 7.10.2 release, so it's not specific to this PR and I won't consider it a blocker for merging. I will, however, make sure we have an issue covering the bug and link it back to this PR. |
On second thought I don't think it's a good idea to update Kibana in a bunch of places to handle ES responding with 400 instead of 404. If you decide to merge this PR before #67958 is fixed then Kibana will only work with |
@elasticmachine update branch |
I think that makes us g2g, much appreciated! |
@elasticmachine update branch |
The default value of Elasticsearch's `action.destructive_requires_rename` has changed to true in elastic/elasticsearch#66908 which causes our integration tests' wildcard deletes to fail. By specifying this config explicitly, we ensure the desired behaviour is selected.
* fix: prevent sub-batch 413's from infinitely retrying whole batch The Http Client breaks batches of actions into sub-batches that are up to 20MB in size, sending larger actions as batches-of-one, and zips the responses together to emulate a single batch response from the Elasticsearch API. When an individual HTTP request is rejected by Elasticsearch (or by an intermediate proxy or load-balancer) with an HTTP/1.1 413, we can emulate the error response instead of blowing an exception through to the whole batch. This allows only the offending events/actions to be subject to retry logic. Along the way, we improve logging at the `debug` level for sub-batches, and emit clear `warn`-level logs with payload sizes when we hit HTTP 413 rejections. * size batch by _decompressed_ payload size * tests: config elasticsearch to allow wildcard deletes The default value of Elasticsearch's `action.destructive_requires_rename` has changed to true in elastic/elasticsearch#66908 which causes our integration tests' wildcard deletes to fail. By specifying this config explicitly, we ensure the desired behaviour is selected.
As per #66908, the setting now defaults to `True`, but it's not shown in the doc. Can we please have the doc updated?
As per #66908, the setting now defaults to `True`, but it's not shown in the doc. Can we please have the doc updated?
As per elastic#66908, the setting now defaults to `True`, but it's not shown in the doc. Can we please have the doc updated?
As per elastic#66908, the setting now defaults to `True`, but it's not shown in the doc. Can we please have the doc updated?
This PR sets the default value of
action.destructive_requires_name
to True. Fixes #61074.