OpenSearch/x-pack/plugin
Jay Modi 515b53d297
Fix race in SLM master/cluster state listeners (#59896)
This change fixes two possible race conditions in SLM related to
how local master changes and cluster state events are observed. When
implementing the `LocalNodeMasterListener` interface, it is only
recommended to execute on a separate threadpool if the operations are
heavy and would block the cluster state thread. SLM specified that the
listeners should run in the Snapshot thread pool, but the operations
in the listener were lightweight. This had the side effect of causing
master changes to be delayed if the Snapshot threads were all busy and
could also potentially cause the `onMaster` and `offMaster` calls to
race if both were queued and then executed concurrently. Additionally,
the `SnapshotLifecycleService` is also a `ClusterStateListener` and
there is currently no order of operations guarantee between
`LocalNodeMasterListeners` and `ClusterStateListeners` so this could
lead to incorrect behavior.

The resolution for these two issues is that the
SnapshotRetentionService now specifies the `SAME` executor for its
implementation of the `LocalNodeMasterListener` interface. The
`SnapshotLifecycleService` is no longer a `LocalNodeMasterListener` and
instead tracks local master changes in its `ClusterStateListner`.

Backport of #59801
2020-07-20 09:59:46 -06:00
..
analytics Fix top_metrics when metric is missing (backport of #59471) (#59881) 2020-07-20 10:42:58 -04:00
async [7.x] EQL: Adds an ability to execute an asynchronous EQL search (#58192) 2020-06-25 14:11:57 -04:00
async-search Fix DLS/FLS permission for the submit async search action (#59693) 2020-07-20 09:37:26 +03:00
autoscaling 7.x - Create plugin for yamlTest task (#56841) (#59090) 2020-07-06 14:16:26 -05:00
ccr Fix estimate size of translog operations (#59206) 2020-07-16 00:19:30 -04:00
core [7.x] Adding new `require_alias` option to indexing requests (#58917) (#59769) 2020-07-17 10:24:58 -04:00
data-streams [7.x] Fix retrieving data stream stats for a DS with multiple backing indices (#59806) (#59810) 2020-07-17 16:56:07 -06:00
deprecation [7.x] Add include_data_streams flag for authorization (#59008) 2020-07-03 12:58:39 -05:00
enrich Add Support in geo_match enrichment policy for any type of geometry (#59276) 2020-07-09 11:41:41 +02:00
eql EQL: Fix matching of tail/desc queries (#59827) 2020-07-19 00:49:16 +03:00
frozen-indices MappedFieldType should not extend FieldType (#58160) 2020-06-16 16:56:43 +01:00
graph 7.x - Create plugin for yamlTest task (#56841) (#59090) 2020-07-06 14:16:26 -05:00
identity-provider Treat roles as a SortedSet (#58988) 2020-07-03 13:40:58 +10:00
ilm Fix race in SLM master/cluster state listeners (#59896) 2020-07-20 09:59:46 -06:00
logstash Remove deprecated usage of testCompile configuration (#57921) (#58083) 2020-06-14 22:30:44 +02:00
mapper-constant-keyword MappedFieldType no longer requires equals/hashCode/clone (#59212) 2020-07-09 21:05:10 +01:00
mapper-flattened Small cleanup for IndexFieldData (#59724) (#59800) 2020-07-17 13:38:15 -04:00
ml [7.x] [ML] add new `custom` field to trained model processors (#59542) (#59700) 2020-07-16 10:57:38 -04:00
monitoring Adding indexing pressure stats to node stats API (#59467) 2020-07-13 17:23:42 -06:00
ql EQL: Obey size request parameter (#59014) 2020-07-06 19:14:25 +03:00
rollup Convert DateFieldMapper to parametrized format (#59429) (#59759) 2020-07-17 12:46:18 +01:00
search-business-rules Unify dependency licenses task configuration (#58116) (#58274) 2020-06-18 08:15:50 +02:00
searchable-snapshots Revert "Mute AzureSearchableSnapshotsIT (#58775)" (#59749) 2020-07-17 10:02:46 +02:00
security Fix DLS/FLS permission for the submit async search action (#59693) 2020-07-20 09:37:26 +03:00
spatial Small cleanup for IndexFieldData (#59724) (#59800) 2020-07-17 13:38:15 -04:00
sql SQL: Implement DATE_PARSE function for parsing strings into DATE values (#57391) (#59699) 2020-07-16 17:24:30 +02:00
src/test Fix top_metrics when metric is missing (backport of #59471) (#59881) 2020-07-20 10:42:58 -04:00
stack Only install stack templates via elected master node (#59624) (#59657) 2020-07-15 22:22:01 +02:00
transform Remove data stream feature flag (#59572) 2020-07-14 23:50:41 +02:00
vectors Small cleanup for IndexFieldData (#59724) (#59800) 2020-07-17 13:38:15 -04:00
voting-only-node Introduce node.roles setting (#58512) 2020-06-25 14:14:51 -04:00
watcher Add the possibility to inject a custom RecoveryState factory to IndexStorePlugin implementations (#59124) 2020-07-15 11:11:07 +02:00
wildcard Small cleanup for IndexFieldData (#59724) (#59800) 2020-07-17 13:38:15 -04:00
build.gradle 7.x - Create plugin for yamlTest task (#56841) (#59090) 2020-07-06 14:16:26 -05:00