-
Notifications
You must be signed in to change notification settings - Fork 24.9k
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
Undocumented(?) change in default for wait_for_active_shards on close index requests #66419
Comments
Pinging @elastic/es-distributed (Team:Distributed) |
Looking at the list of changes when the replication of closed indices was merged in master (#39499) and more precisely at #38854 I see nothing that documents the So I agree with you and I think the NONE to DEFAULT move should be documented as breaking in 8.0. |
In 8.x the default for `?wait_for_active_shards` will change from `NONE` to `DEFAULT` on calls to `POST /index/_close`. This commit adds a deprecation warning in 7.x if this parameter is not specified to encourage users to adopt the new behaviour before upgrading. Closes elastic#66419
In 8.x the default for `?wait_for_active_shards` changes from `NONE` to `DEFAULT` on calls to `POST /index/_close`. This commit adds this change to the breaking changes docs. Relates elastic#66419, elastic#66542
Today you cannot explicitly indicate that an operation should use the usual behaviour of waiting for active shards according to the underlying index setting. This is a problem for the close index API which has a default of `none` in 7.x for BWC reasons (see elastic#33888), but the usual behaviour in 8.0: you cannot today opt-in to the 8.0 behaviour with this parameter. This commit adds support for the literal value `default` for the `wait_for_active_shards` query parameter. Relates elastic#66419
I think it was JFK that once said
It turns out we have to add a new value to the |
In 7.x the close indices API defaulted to `?wait_for_active_shards=0` but from 8.0 it defaults to respecting the index settings instead. This commit introduces the `index-setting` value for this parameter on this API allowing users to opt-in to the future behaviour today, and emits a deprecation warning indicating that the default no longer needs to be used and will be unsupported in future. In 7.x a follow up PR will introduce support for the same `index-setting` value for this parameter and will emit deprecation warnings if users try and use the default instead. Relates elastic#66419
In 7.x the close indices API defaulted to `?wait_for_active_shards=0` but from 8.0 it defaults to respecting the index settings instead. This commit introduces the `index-setting` value for this parameter on this API allowing users to opt-in to the future behaviour today, and emits a deprecation warning indicating that the default no longer needs to be used and will be unsupported in future. In 7.x a follow up PR will introduce support for the same `index-setting` value for this parameter and will emit deprecation warnings if users try and use the default instead. Relates #66419
In 7.x the close indices API defaults to `?wait_for_active_shards=0` but from 8.0 it will default to respecting the index settings instead. This commit introduces the `index-setting` value for this parameter on this API allowing users to opt-in to the future behaviour today, and starts to emit a deprecation warning for users that use the default. Relates elastic#67158 Closes elastic#66419
In 7.x the close indices API defaults to `?wait_for_active_shards=0` but from 8.0 it will default to respecting the index settings instead. This commit introduces the `index-setting` value for this parameter on this API allowing users to opt-in to the future behaviour today, and starts to emit a deprecation warning for users that use the default. Relates #67158 Closes #66419
This is still open because #67246 was reverted, see #67246 (comment). |
Part of the fixes for elastic#66419, this commit permits nodes to emit the deprecation warning regarding not specifying `?wait_for_active_shards` when closing an index in 7.x versions for x ≥ 12. This change is required on `master` too since the BWC tests encounter these warnings. Relates elastic#67246, which is the 7.x part of this change.
Part of the fixes for #66419, this commit permits nodes to emit the deprecation warning regarding not specifying `?wait_for_active_shards` when closing an index in 7.x versions for x ≥ 12. This change is required on `master` too since the BWC tests encounter these warnings. Relates #67246, which is the 7.x part of this change.
In 7.x the close indices API defaults to `?wait_for_active_shards=0` but from 8.0 it will default to respecting the index settings instead. This commit introduces the `index-setting` value for this parameter on this API allowing users to opt-in to the future behaviour today, and starts to emit a deprecation warning for users that use the default. Relates elastic#67158 Retry of elastic#67246 now that elastic#67498 is merged to `master` Closes elastic#66419
In 7.x the close indices API defaults to `?wait_for_active_shards=0` but from 8.0 it will default to respecting the index settings instead. This commit introduces the `index-setting` value for this parameter on this API allowing users to opt-in to the future behaviour today, and starts to emit a deprecation warning for users that use the default. Relates #67158 Retry of #67246 now that #67498 is merged to `master` Closes #66419
Closed by #67527 |
In 7.x the default for
?wait_for_active_shards
on aPOST /index/_close
request isNONE
(i.e. do not wait) whereas in 8.0 it defaults toDEFAULT
(i.e. whatever the index metadata says). I took a quick look at the breaking changes docs for 8.0 and didn't see this mentioned, and nor do I see anywhere that we're emitting deprecation logs indicating the change in behaviour.This caught me out when writing some tests (see #66415). Should we consider this a breaking change and warn on cases where folk are relying on it? Perhaps not, it might not break anything. I'm opening this issue to remind us to discuss it at some point before releasing 8.0.
@tlrx WDYT?
The text was updated successfully, but these errors were encountered: