-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Description
Currently we serialize if a data stream has the failure store explicitly enabled when writing a data stream to XContent and to a byte stream. This is redundant because we always send the data stream options for the data stream which already have this setting inside of them. This is a vestigial field from early in failure store's dev cycle that has yet to be cleared up. Now that the feature is going into GA - logic that uses values provided to this field has be cleared up to ignore it. It doesn't look like the field is currently written in XContent. We should look toward clearing it out.
elasticsearch/server/src/main/java/org/elasticsearch/cluster/metadata/DataStream.java
Lines 1253 to 1256 in d928d1a
| if (out.getTransportVersion() | |
| .between(DataStream.ADDED_FAILURE_STORE_TRANSPORT_VERSION, DataStream.ADD_DATA_STREAM_OPTIONS_VERSION)) { | |
| out.writeBoolean(isFailureStoreExplicitlyEnabled()); | |
| } |
elasticsearch/server/src/main/java/org/elasticsearch/cluster/metadata/DataStream.java
Line 1286 in d928d1a
| public static final ParseField FAILURE_STORE_FIELD = new ParseField("failure_store"); |
elasticsearch/server/src/main/java/org/elasticsearch/cluster/metadata/DataStream.java
Lines 1366 to 1367 in d928d1a
| // Should be removed after backport | |
| PARSER.declareBoolean(ConstructingObjectParser.optionalConstructorArg(), FAILURE_STORE_FIELD); |