diff --git a/server/src/main/java/org/elasticsearch/action/resync/ResyncReplicationRequest.java b/server/src/main/java/org/elasticsearch/action/resync/ResyncReplicationRequest.java index a53766af7cf52..2ec0e9200d436 100644 --- a/server/src/main/java/org/elasticsearch/action/resync/ResyncReplicationRequest.java +++ b/server/src/main/java/org/elasticsearch/action/resync/ResyncReplicationRequest.java @@ -66,7 +66,8 @@ public Translog.Operation[] getOperations() { @Override public void readFrom(final StreamInput in) throws IOException { - assert Version.CURRENT.major <= 7; + // TODO: https://github.com/elastic/elasticsearch/issues/38556 + //assert Version.CURRENT.major <= 7; if (in.getVersion().equals(Version.V_6_0_0)) { /* * Resync replication request serialization was broken in 6.0.0 due to the elements of the stream not being prefixed with a diff --git a/server/src/main/java/org/elasticsearch/cluster/metadata/MetaDataCreateIndexService.java b/server/src/main/java/org/elasticsearch/cluster/metadata/MetaDataCreateIndexService.java index 838b1e2547204..2e18e5aeae50a 100644 --- a/server/src/main/java/org/elasticsearch/cluster/metadata/MetaDataCreateIndexService.java +++ b/server/src/main/java/org/elasticsearch/cluster/metadata/MetaDataCreateIndexService.java @@ -590,7 +590,8 @@ public ClusterState execute(ClusterState currentState) throws Exception { static int getNumberOfShards(final Settings.Builder indexSettingsBuilder) { // TODO: this logic can be removed when the current major version is 8 - assert Version.CURRENT.major == 7; + // TODO: https://github.com/elastic/elasticsearch/issues/38556 + // assert Version.CURRENT.major == 7; final int numberOfShards; final Version indexVersionCreated = Version.fromId(Integer.parseInt(indexSettingsBuilder.get(IndexMetaData.SETTING_INDEX_VERSION_CREATED.getKey()))); diff --git a/server/src/main/java/org/elasticsearch/gateway/MetaStateService.java b/server/src/main/java/org/elasticsearch/gateway/MetaStateService.java index 04bd4b5341652..d67cdccb9a09b 100644 --- a/server/src/main/java/org/elasticsearch/gateway/MetaStateService.java +++ b/server/src/main/java/org/elasticsearch/gateway/MetaStateService.java @@ -117,7 +117,8 @@ private Tuple loadFullStateBWC() throws IOException { if (globalMetaData != null) { metaDataBuilder = MetaData.builder(globalMetaData); -// assert Version.CURRENT.major < 8 : "failed to find manifest file, which is mandatory staring with Elasticsearch version 8.0"; + // TODO https://github.com/elastic/elasticsearch/issues/38556 + // assert Version.CURRENT.major < 8 : "failed to find manifest file, which is mandatory staring with Elasticsearch version 8.0"; } else { metaDataBuilder = MetaData.builder(); } @@ -126,7 +127,8 @@ private Tuple loadFullStateBWC() throws IOException { Tuple indexMetaDataAndGeneration = INDEX_META_DATA_FORMAT.loadLatestStateWithGeneration(logger, namedXContentRegistry, nodeEnv.resolveIndexFolder(indexFolderName)); -// assert Version.CURRENT.major < 8 : "failed to find manifest file, which is mandatory staring with Elasticsearch version 8.0"; + // TODO https://github.com/elastic/elasticsearch/issues/38556 + // assert Version.CURRENT.major < 8 : "failed to find manifest file, which is mandatory staring with Elasticsearch version 8.0"; IndexMetaData indexMetaData = indexMetaDataAndGeneration.v1(); long generation = indexMetaDataAndGeneration.v2(); if (indexMetaData != null) { diff --git a/server/src/main/java/org/elasticsearch/transport/RemoteClusterAware.java b/server/src/main/java/org/elasticsearch/transport/RemoteClusterAware.java index 9b9243b612b74..ff06e59d4f729 100644 --- a/server/src/main/java/org/elasticsearch/transport/RemoteClusterAware.java +++ b/server/src/main/java/org/elasticsearch/transport/RemoteClusterAware.java @@ -57,7 +57,8 @@ public abstract class RemoteClusterAware { static { // remove search.remote.* settings in 8.0.0 - assert Version.CURRENT.major < 8; + // TODO https://github.com/elastic/elasticsearch/issues/38556 + // assert Version.CURRENT.major < 8; } public static final Setting.AffixSetting> SEARCH_REMOTE_CLUSTERS_SEEDS = diff --git a/server/src/main/java/org/elasticsearch/transport/RemoteClusterService.java b/server/src/main/java/org/elasticsearch/transport/RemoteClusterService.java index 009ee48dd8a99..a126337aa0e54 100644 --- a/server/src/main/java/org/elasticsearch/transport/RemoteClusterService.java +++ b/server/src/main/java/org/elasticsearch/transport/RemoteClusterService.java @@ -69,7 +69,8 @@ public final class RemoteClusterService extends RemoteClusterAware implements Cl static { // remove search.remote.* settings in 8.0.0 - assert Version.CURRENT.major < 8; + // TODO + // assert Version.CURRENT.major < 8; } public static final Setting SEARCH_REMOTE_CONNECTIONS_PER_CLUSTER =