mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-04-24 23:27:25 -04:00
Define owners for UpdateForV9
annotations (#113926)
In order to better track the work needed to prepare this branch for the major version upgrade, this commit adds a mandatory `owner` field to all `UpdateForV9` (and `UpdateForV10`) annotations.
This commit is contained in:
parent
f9921168f5
commit
81bd8667cb
106 changed files with 210 additions and 163 deletions
|
@ -22,7 +22,7 @@ public enum RestApiVersion {
|
|||
|
||||
V_8(8),
|
||||
|
||||
@UpdateForV9 // remove all references to V_7 then delete this annotation
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // remove all references to V_7 then delete this annotation
|
||||
V_7(7);
|
||||
|
||||
public final byte major;
|
||||
|
|
|
@ -21,4 +21,22 @@ import java.lang.annotation.Target;
|
|||
@Retention(RetentionPolicy.SOURCE)
|
||||
@Target({ ElementType.LOCAL_VARIABLE, ElementType.CONSTRUCTOR, ElementType.FIELD, ElementType.METHOD, ElementType.TYPE })
|
||||
public @interface UpdateForV10 {
|
||||
enum Owner {
|
||||
CORE_INFRA,
|
||||
DATA_MANAGEMENT,
|
||||
DISTRIBUTED_COORDINATION,
|
||||
DISTRIBUTED_INDEXING,
|
||||
ENTERPRISE_SEARCH,
|
||||
MACHINE_LEARNING,
|
||||
PROFILING,
|
||||
SEARCH_ANALYTICS,
|
||||
SEARCH_FOUNDATIONS,
|
||||
SEARCH_RELEVANCE,
|
||||
SECURITY,
|
||||
}
|
||||
|
||||
/**
|
||||
* The owning team of the task to act on this annotation when the time comes.
|
||||
*/
|
||||
Owner owner();
|
||||
}
|
||||
|
|
|
@ -21,4 +21,22 @@ import java.lang.annotation.Target;
|
|||
@Retention(RetentionPolicy.SOURCE)
|
||||
@Target({ ElementType.LOCAL_VARIABLE, ElementType.CONSTRUCTOR, ElementType.FIELD, ElementType.METHOD, ElementType.TYPE })
|
||||
public @interface UpdateForV9 {
|
||||
enum Owner {
|
||||
CORE_INFRA,
|
||||
DATA_MANAGEMENT,
|
||||
DISTRIBUTED_COORDINATION,
|
||||
DISTRIBUTED_INDEXING,
|
||||
ENTERPRISE_SEARCH,
|
||||
MACHINE_LEARNING,
|
||||
PROFILING,
|
||||
SEARCH_ANALYTICS,
|
||||
SEARCH_FOUNDATIONS,
|
||||
SEARCH_RELEVANCE,
|
||||
SECURITY,
|
||||
}
|
||||
|
||||
/**
|
||||
* The owning team of the task to act on this annotation when the time comes.
|
||||
*/
|
||||
Owner owner();
|
||||
}
|
||||
|
|
|
@ -241,7 +241,8 @@ public final class AttachmentProcessor extends AbstractProcessor {
|
|||
int indexedChars = readIntProperty(TYPE, processorTag, config, "indexed_chars", NUMBER_OF_CHARS_INDEXED);
|
||||
boolean ignoreMissing = readBooleanProperty(TYPE, processorTag, config, "ignore_missing", false);
|
||||
String indexedCharsField = readOptionalStringProperty(TYPE, processorTag, config, "indexed_chars_field");
|
||||
@UpdateForV9 // update the [remove_binary] default to be 'true' assuming enough time has passed. Deprecated in September 2022.
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
// update the [remove_binary] default to be 'true' assuming enough time has passed. Deprecated in September 2022.
|
||||
Boolean removeBinary = readOptionalBooleanProperty(TYPE, processorTag, config, "remove_binary");
|
||||
if (removeBinary == null) {
|
||||
DEPRECATION_LOGGER.warn(
|
||||
|
|
|
@ -34,7 +34,7 @@ import java.util.concurrent.TimeUnit;
|
|||
|
||||
import static org.hamcrest.Matchers.contains;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
@LuceneTestCase.AwaitsFix(bugUrl = "we need to figure out the index migrations here for 9.0")
|
||||
public class FullClusterRestartIT extends ParameterizedFullClusterRestartTestCase {
|
||||
|
||||
|
|
|
@ -344,7 +344,7 @@ public class GeoJsonShapeParserTests extends BaseGeoParsingTestCase {
|
|||
assertGeometryEquals(p, polygonGeoJson, false);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@AwaitsFix(bugUrl = "this test is using pre 8.0.0 index versions so needs to be removed or updated")
|
||||
public void testParse3DPolygon() throws IOException, ParseException {
|
||||
XContentBuilder polygonGeoJson = XContentFactory.jsonBuilder()
|
||||
|
|
|
@ -303,7 +303,7 @@ public class GeoWKTShapeParserTests extends BaseGeoParsingTestCase {
|
|||
assertThat(e, hasToString(containsString("coordinate dimensions do not match")));
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@AwaitsFix(bugUrl = "this test is using pre 8.0.0 index versions so needs to be removed or updated")
|
||||
public void testParseMixedDimensionPolyWithHoleStoredZ() throws IOException {
|
||||
List<Coordinate> shellCoordinates = new ArrayList<>();
|
||||
|
@ -338,7 +338,7 @@ public class GeoWKTShapeParserTests extends BaseGeoParsingTestCase {
|
|||
assertThat(e, hasToString(containsString("unable to add coordinate to CoordinateBuilder: coordinate dimensions do not match")));
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@AwaitsFix(bugUrl = "this test is using pre 8.0.0 index versions so needs to be removed or updated")
|
||||
public void testParsePolyWithStoredZ() throws IOException {
|
||||
List<Coordinate> shellCoordinates = new ArrayList<>();
|
||||
|
@ -363,7 +363,7 @@ public class GeoWKTShapeParserTests extends BaseGeoParsingTestCase {
|
|||
assertEquals(shapeBuilder.numDimensions(), 3);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@AwaitsFix(bugUrl = "this test is using pre 8.0.0 index versions so needs to be removed or updated")
|
||||
public void testParseOpenPolygon() throws IOException {
|
||||
String openPolygon = "POLYGON ((100 5, 100 10, 90 10, 90 5))";
|
||||
|
|
|
@ -56,7 +56,7 @@ import static org.mockito.Mockito.mock;
|
|||
import static org.mockito.Mockito.when;
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@AwaitsFix(bugUrl = "this is testing legacy functionality so can likely be removed in 9.0")
|
||||
public class LegacyGeoShapeFieldMapperTests extends MapperTestCase {
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ import java.io.IOException;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@LuceneTestCase.AwaitsFix(bugUrl = "this is testing legacy functionality so can likely be removed in 9.0")
|
||||
public class LegacyGeoShapeFieldTypeTests extends FieldTypeTestCase {
|
||||
|
||||
|
|
|
@ -1207,7 +1207,7 @@ public class FullClusterRestartIT extends ParameterizedFullClusterRestartTestCas
|
|||
closeIndex(index);
|
||||
}
|
||||
|
||||
@UpdateForV9 // This check can be removed (always assume true)
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_INDEXING) // This check can be removed (always assume true)
|
||||
var originalClusterSupportsReplicationOfClosedIndices = oldClusterHasFeature(RestTestLegacyFeatures.REPLICATION_OF_CLOSED_INDICES);
|
||||
|
||||
if (originalClusterSupportsReplicationOfClosedIndices) {
|
||||
|
@ -1608,7 +1608,7 @@ public class FullClusterRestartIT extends ParameterizedFullClusterRestartTestCas
|
|||
@SuppressWarnings("unchecked")
|
||||
public void testSystemIndexMetadataIsUpgraded() throws Exception {
|
||||
|
||||
@UpdateForV9 // assumeTrue can be removed (condition always true)
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // assumeTrue can be removed (condition always true)
|
||||
var originalClusterTaskIndexIsSystemIndex = oldClusterHasFeature(RestTestLegacyFeatures.TASK_INDEX_SYSTEM_INDEX);
|
||||
assumeTrue(".tasks became a system index in 7.10.0", originalClusterTaskIndexIsSystemIndex);
|
||||
final String systemIndexWarning = "this request accesses system indices: [.tasks], but in a future major version, direct "
|
||||
|
@ -1729,7 +1729,7 @@ public class FullClusterRestartIT extends ParameterizedFullClusterRestartTestCas
|
|||
/**
|
||||
* This test ensures that soft deletes are enabled a when upgrading a pre-8 cluster to 8.0+
|
||||
*/
|
||||
@UpdateForV9 // This test can be removed in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // This test can be removed in v9
|
||||
public void testEnableSoftDeletesOnRestore() throws Exception {
|
||||
var originalClusterDidNotEnforceSoftDeletes = oldClusterHasFeature(RestTestLegacyFeatures.SOFT_DELETES_ENFORCED) == false;
|
||||
|
||||
|
@ -1842,7 +1842,7 @@ public class FullClusterRestartIT extends ParameterizedFullClusterRestartTestCas
|
|||
* with true/false as options. This test ensures that the old boolean setting in cluster state is
|
||||
* translated properly. This test can be removed in 9.0.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
public void testTransportCompressionSetting() throws IOException {
|
||||
var originalClusterBooleanCompressSetting = oldClusterHasFeature(RestTestLegacyFeatures.NEW_TRANSPORT_COMPRESSED_SETTING) == false;
|
||||
assumeTrue("the old transport.compress setting existed before 7.14", originalClusterBooleanCompressSetting);
|
||||
|
|
|
@ -250,7 +250,7 @@ public class QueryBuilderBWCIT extends ParameterizedFullClusterRestartTestCase {
|
|||
StreamInput input = new NamedWriteableAwareStreamInput(new InputStreamStreamInput(in), registry)
|
||||
) {
|
||||
|
||||
@UpdateForV9 // condition will always be true
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_FOUNDATIONS) // condition will always be true
|
||||
var originalClusterHasTransportVersion = oldClusterHasFeature(RestTestLegacyFeatures.TRANSPORT_VERSION_SUPPORTED);
|
||||
final TransportVersion transportVersion;
|
||||
if (originalClusterHasTransportVersion == false) {
|
||||
|
|
|
@ -20,7 +20,7 @@ import java.util.List;
|
|||
|
||||
import static org.elasticsearch.test.hamcrest.OptionalMatchers.isPresentWith;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public class NodesCapabilitiesUpgradeIT extends AbstractRollingUpgradeTestCase {
|
||||
|
||||
private static Boolean upgradingBeforeCapabilities;
|
||||
|
|
|
@ -42,7 +42,7 @@ public class ClientYamlTestSuiteIT extends ESClientYamlSuiteTestCase {
|
|||
super(testCandidate);
|
||||
}
|
||||
|
||||
@UpdateForV9 // remove restCompat check
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // remove restCompat check
|
||||
@ParametersFactory
|
||||
public static Iterable<Object[]> parameters() throws Exception {
|
||||
String restCompatProperty = System.getProperty("tests.restCompat");
|
||||
|
|
|
@ -62,7 +62,7 @@ import static org.hamcrest.Matchers.hasSize;
|
|||
* that the {@link ReplicaShardAllocator} prefers copies with matching sync_id.
|
||||
*/
|
||||
@ESIntegTestCase.ClusterScope(scope = ESIntegTestCase.Scope.TEST, numDataNodes = 0)
|
||||
@UpdateForV9 // remove this test in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // remove this test in v9
|
||||
public class ReplicaShardAllocatorSyncIdIT extends ESIntegTestCase {
|
||||
|
||||
private static final AtomicBoolean allowFlush = new AtomicBoolean();
|
||||
|
|
|
@ -35,7 +35,7 @@ public class MalformedDynamicTemplateIT extends ESIntegTestCase {
|
|||
* contains unknown parameters. We were able to create those templates in 7.x still, so we need
|
||||
* to be able to index new documents into them. Indexing should issue a deprecation warning though.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
@AwaitsFix(bugUrl = "this is testing 7.x specific compatibility which may be n/a now after 9.0 bump")
|
||||
public void testBWCMalformedDynamicTemplate() {
|
||||
// this parameter is not supported by "keyword" field type
|
||||
|
|
|
@ -109,7 +109,7 @@ public class IndexSnapshotsServiceIT extends AbstractSnapshotIntegTestCase {
|
|||
expectThrows(IllegalArgumentException.class, () -> getLatestSnapshotForShardFuture(Collections.emptyList(), "idx", 0, false));
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
// below we were selecting an index version between current and 7.5.0, this has been updated to 8.0.0 now but that might need to change
|
||||
public void testGetShardSnapshotReturnsTheLatestSuccessfulSnapshot() throws Exception {
|
||||
final String repoName = "repo-name";
|
||||
|
|
|
@ -114,8 +114,8 @@ public class ReleaseVersions {
|
|||
// this will no longer be the case with ES 10 (which won't know about ES v8.x where we introduced separated versions)
|
||||
// maybe keep the release mapping around in the csv file?
|
||||
// SEP for now
|
||||
@UpdateForV9
|
||||
// @UpdateForV10
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
// @UpdateForV10(owner = UpdateForV10.Owner.CORE_INFRA)
|
||||
Version oldVersion = Version.fromId(id);
|
||||
return oldVersion.toString();
|
||||
}
|
||||
|
|
|
@ -50,7 +50,7 @@ public class TransportVersions {
|
|||
return new TransportVersion(id);
|
||||
}
|
||||
|
||||
@UpdateForV9 // remove the transport versions with which v9 will not need to interact
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // remove the transport versions with which v9 will not need to interact
|
||||
public static final TransportVersion ZERO = def(0);
|
||||
public static final TransportVersion V_7_0_0 = def(7_00_00_99);
|
||||
public static final TransportVersion V_7_0_1 = def(7_00_01_99);
|
||||
|
@ -289,7 +289,7 @@ public class TransportVersions {
|
|||
* Reference to the earliest compatible transport version to this version of the codebase.
|
||||
* This should be the transport version used by the highest minor version of the previous major.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
// This needs to be bumped to the 8.last
|
||||
public static final TransportVersion MINIMUM_COMPATIBLE = V_7_17_0;
|
||||
|
||||
|
|
|
@ -232,7 +232,7 @@ public class Version implements VersionId<Version>, ToXContentFragment {
|
|||
VERSION_STRINGS = Map.copyOf(builderByString);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
// Re-enable this assertion once the rest api version is bumped
|
||||
private static void assertRestApiVersion() {
|
||||
// assert RestApiVersion.current().major == CURRENT.major && RestApiVersion.previous().major == CURRENT.major - 1
|
||||
|
|
|
@ -56,7 +56,7 @@ public class TransportGetFeatureUpgradeStatusAction extends TransportMasterNodeA
|
|||
/**
|
||||
* Once all feature migrations for 8.x -> 9.x have been tested, we can bump this to Version.V_8_0_0
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final Version NO_UPGRADE_REQUIRED_VERSION = Version.V_7_0_0;
|
||||
public static final IndexVersion NO_UPGRADE_REQUIRED_INDEX_VERSION = IndexVersions.V_7_0_0;
|
||||
|
||||
|
@ -64,7 +64,7 @@ public class TransportGetFeatureUpgradeStatusAction extends TransportMasterNodeA
|
|||
PersistentTasksService persistentTasksService;
|
||||
|
||||
@Inject
|
||||
@UpdateForV9 // Once we begin working on 9.x, we need to update our migration classes
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // Once we begin working on 9.x, we need to update our migration classes
|
||||
public TransportGetFeatureUpgradeStatusAction(
|
||||
TransportService transportService,
|
||||
ThreadPool threadPool,
|
||||
|
|
|
@ -152,7 +152,7 @@ public class TransportNodesCapabilitiesAction extends TransportNodesAction<
|
|||
this.restApiVersion = restApiVersion;
|
||||
}
|
||||
|
||||
@UpdateForV9 // 8.x blows up in a mixed cluster when trying to read RestApiVersion.forMajor(9)
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // 8.x blows up in a mixed cluster when trying to read RestApiVersion.forMajor(9)
|
||||
// ./gradlew ":qa:mixed-cluster:v8.16.0#mixedClusterTest"
|
||||
// -Dtests.class="org.elasticsearch.backwards.MixedClusterClientYamlTestSuiteIT"
|
||||
// -Dtests.method="test {p0=capabilities/10_basic/Capabilities API}"
|
||||
|
|
|
@ -27,7 +27,7 @@ import org.elasticsearch.transport.TransportService;
|
|||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
// @UpdateForV10 // this can be removed in v10. It may be called by v8 nodes to v9 nodes.
|
||||
public class TransportNodesFeaturesAction extends TransportNodesAction<
|
||||
NodesFeaturesRequest,
|
||||
|
|
|
@ -35,7 +35,7 @@ public class GetSnapshotsResponse extends ActionResponse implements ChunkedToXCo
|
|||
|
||||
private final List<SnapshotInfo> snapshots;
|
||||
|
||||
@UpdateForV9 // always empty, can be dropped
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // always empty, can be dropped
|
||||
private final Map<String, ElasticsearchException> failures;
|
||||
|
||||
@Nullable
|
||||
|
|
|
@ -306,7 +306,7 @@ public class TransportClusterStatsAction extends TransportNodesAction<
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9 // this can be replaced with TransportRequest.Empty in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT) // this can be replaced with TransportRequest.Empty in v9
|
||||
public static class ClusterStatsNodeRequest extends TransportRequest {
|
||||
|
||||
ClusterStatsNodeRequest() {}
|
||||
|
|
|
@ -454,7 +454,7 @@ public final class BulkRequestParser {
|
|||
return isIncremental ? consumed : from;
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_INDEXING)
|
||||
// Warnings will need to be replaced with XContentEOFException from 9.x
|
||||
private static void warnBulkActionNotProperlyClosed(String message) {
|
||||
deprecationLogger.compatibleCritical(STRICT_ACTION_PARSING_WARNING_KEY, message);
|
||||
|
|
|
@ -391,7 +391,7 @@ public class ClusterModule extends AbstractModule {
|
|||
}
|
||||
}
|
||||
|
||||
@UpdateForV10 // in v10 there is only one allocator
|
||||
@UpdateForV10(owner = UpdateForV10.Owner.DISTRIBUTED_COORDINATION) // in v10 there is only one allocator
|
||||
private static ShardsAllocator createShardsAllocator(
|
||||
Settings settings,
|
||||
ClusterSettings clusterSettings,
|
||||
|
|
|
@ -177,7 +177,7 @@ public class JoinValidationService {
|
|||
}
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
private void legacyValidateJoin(DiscoveryNode discoveryNode, ActionListener<Void> listener, Transport.Connection connection) {
|
||||
final var responseHandler = TransportResponseHandler.empty(responseExecutor, listener.delegateResponse((l, e) -> {
|
||||
logger.warn(() -> "failed to validate incoming join request from node [" + discoveryNode + "]", e);
|
||||
|
|
|
@ -43,7 +43,7 @@ import java.util.Set;
|
|||
import java.util.concurrent.Executor;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@UpdateForV9 // this can be removed in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // this can be removed in v9
|
||||
public class NodeFeaturesFixupListener implements ClusterStateListener {
|
||||
|
||||
private static final Logger logger = LogManager.getLogger(NodeFeaturesFixupListener.class);
|
||||
|
|
|
@ -58,7 +58,7 @@ public final class DesiredNode implements Writeable, ToXContentObject, Comparabl
|
|||
private static final ParseField PROCESSORS_RANGE_FIELD = new ParseField("processors_range");
|
||||
private static final ParseField MEMORY_FIELD = new ParseField("memory");
|
||||
private static final ParseField STORAGE_FIELD = new ParseField("storage");
|
||||
@UpdateForV9 // Remove deprecated field
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // Remove deprecated field
|
||||
private static final ParseField VERSION_FIELD = new ParseField("node_version");
|
||||
|
||||
public static final ConstructingObjectParser<DesiredNode, Void> PARSER = new ConstructingObjectParser<>(
|
||||
|
@ -118,7 +118,7 @@ public final class DesiredNode implements Writeable, ToXContentObject, Comparabl
|
|||
private final ByteSizeValue memory;
|
||||
private final ByteSizeValue storage;
|
||||
|
||||
@UpdateForV9 // Remove deprecated version field
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // Remove deprecated version field
|
||||
private final String version;
|
||||
private final String externalId;
|
||||
private final Set<DiscoveryNodeRole> roles;
|
||||
|
@ -278,7 +278,7 @@ public final class DesiredNode implements Writeable, ToXContentObject, Comparabl
|
|||
addDeprecatedVersionField(builder);
|
||||
}
|
||||
|
||||
@UpdateForV9 // Remove deprecated field from response
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // Remove deprecated field from response
|
||||
private void addDeprecatedVersionField(XContentBuilder builder) throws IOException {
|
||||
if (version != null) {
|
||||
builder.field(VERSION_FIELD.getPreferredName(), version);
|
||||
|
|
|
@ -160,7 +160,7 @@ public class DiskThresholdSettings implements Writeable {
|
|||
checkAutoReleaseIndexEnabled();
|
||||
}
|
||||
|
||||
@UpdateForV9 // this check is unnecessary in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // this check is unnecessary in v9
|
||||
private static void checkAutoReleaseIndexEnabled() {
|
||||
final String AUTO_RELEASE_INDEX_ENABLED_KEY = "es.disk.auto_release_flood_stage_block";
|
||||
final String property = System.getProperty(AUTO_RELEASE_INDEX_ENABLED_KEY);
|
||||
|
|
|
@ -149,7 +149,7 @@ public class BalancedShardsAllocator implements ShardsAllocator {
|
|||
*
|
||||
* Once {@link org.elasticsearch.Version#V_7_17_0} goes out of scope, start to properly reject such bad values.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
private static float ensureValidThreshold(float threshold) {
|
||||
if (1.0f <= threshold) {
|
||||
return threshold;
|
||||
|
|
|
@ -72,7 +72,7 @@ public class DiskThresholdDecider extends AllocationDecider {
|
|||
|
||||
public static final String NAME = "disk_threshold";
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
public static final Setting<Boolean> ENABLE_FOR_SINGLE_DATA_NODE = Setting.boolSetting(
|
||||
"cluster.routing.allocation.disk.watermark.enable_for_single_data_node",
|
||||
true,
|
||||
|
|
|
@ -50,7 +50,7 @@ import static org.elasticsearch.cluster.ClusterState.INFERRED_TRANSPORT_VERSION;
|
|||
* due to the master node not understanding cluster state with transport versions added in 8.8.0.
|
||||
* Any nodes with the inferred placeholder cluster state is then refreshed with their actual transport version
|
||||
*/
|
||||
@UpdateForV9 // this can be removed in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // this can be removed in v9
|
||||
public class TransportVersionsFixupListener implements ClusterStateListener {
|
||||
|
||||
private static final Logger logger = LogManager.getLogger(TransportVersionsFixupListener.class);
|
||||
|
|
|
@ -150,7 +150,7 @@ public class Setting<T> implements ToXContentObject {
|
|||
* Indicates that this index-level setting was deprecated in {@link Version#V_7_17_0} and is
|
||||
* forbidden in indices created from {@link Version#V_8_0_0} onwards.
|
||||
*/
|
||||
@UpdateForV9 // introduce IndexSettingDeprecatedInV8AndRemovedInV9 to replace this constant
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // introduce IndexSettingDeprecatedInV8AndRemovedInV9 to replace this constant
|
||||
IndexSettingDeprecatedInV7AndRemovedInV8,
|
||||
|
||||
/**
|
||||
|
@ -639,7 +639,7 @@ public class Setting<T> implements ToXContentObject {
|
|||
if (this.isDeprecated() && this.exists(settings)) {
|
||||
// It would be convenient to show its replacement key, but replacement is often not so simple
|
||||
final String key = getKey();
|
||||
@UpdateForV9 // https://github.com/elastic/elasticsearch/issues/79666
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // https://github.com/elastic/elasticsearch/issues/79666
|
||||
String message = "[{}] setting was deprecated in Elasticsearch and will be removed in a future release.";
|
||||
if (this.isDeprecatedWarningOnly()) {
|
||||
Settings.DeprecationLoggerHolder.deprecationLogger.warn(DeprecationCategory.SETTINGS, key, message, key);
|
||||
|
|
|
@ -59,7 +59,7 @@ public class DateFormatters {
|
|||
* Note that this property is sometimes set by {@code ESTestCase.setTestSysProps} to flip between implementations in tests,
|
||||
* to ensure both are fully tested
|
||||
*/
|
||||
@UpdateForV9 // evaluate if we need to deprecate/remove this
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // evaluate if we need to deprecate/remove this
|
||||
private static final boolean JAVA_TIME_PARSERS_ONLY = Booleans.parseBoolean(System.getProperty("es.datetime.java_time_parsers"), false);
|
||||
|
||||
static {
|
||||
|
|
|
@ -42,7 +42,7 @@ public final class NodeMetadata {
|
|||
|
||||
private final IndexVersion oldestIndexVersion;
|
||||
|
||||
@UpdateForV9 // version should be non-null in the node metadata from v9 onwards
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // version should be non-null in the node metadata from v9 onwards
|
||||
private NodeMetadata(
|
||||
final String nodeId,
|
||||
final BuildVersion buildVersion,
|
||||
|
@ -112,7 +112,7 @@ public final class NodeMetadata {
|
|||
return oldestIndexVersion;
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public void verifyUpgradeToCurrentVersion() {
|
||||
// Enable the following assertion for V9:
|
||||
// assert (nodeVersion.equals(BuildVersion.empty()) == false) : "version is required in the node metadata from v9 onwards";
|
||||
|
@ -163,7 +163,7 @@ public final class NodeMetadata {
|
|||
this.oldestIndexVersion = IndexVersion.fromId(oldestIndexVersion);
|
||||
}
|
||||
|
||||
@UpdateForV9 // version is required in the node metadata from v9 onwards
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // version is required in the node metadata from v9 onwards
|
||||
public NodeMetadata build() {
|
||||
final IndexVersion oldestIndexVersion;
|
||||
|
||||
|
|
|
@ -186,7 +186,7 @@ public class GatewayMetaState implements Closeable {
|
|||
long currentTerm = onDiskState.currentTerm;
|
||||
|
||||
if (onDiskState.empty()) {
|
||||
@UpdateForV9 // legacy metadata loader is not needed anymore from v9 onwards
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION) // legacy metadata loader is not needed anymore from v9 onwards
|
||||
final Tuple<Manifest, Metadata> legacyState = metaStateService.loadFullState();
|
||||
if (legacyState.v1().isEmpty() == false) {
|
||||
metadata = legacyState.v2();
|
||||
|
|
|
@ -56,7 +56,7 @@ public class MetaStateService {
|
|||
* meta state with globalGeneration -1 and empty meta data is returned.
|
||||
* @throws IOException if some IOException when loading files occurs or there is no metadata referenced by manifest file.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
public Tuple<Manifest, Metadata> loadFullState() throws IOException {
|
||||
final Manifest manifest = Manifest.FORMAT.loadLatestState(logger, namedXContentRegistry, nodeEnv.nodeDataPaths());
|
||||
if (manifest == null) {
|
||||
|
|
|
@ -48,7 +48,7 @@ public class IndexVersions {
|
|||
return new IndexVersion(id, luceneVersion);
|
||||
}
|
||||
|
||||
@UpdateForV9 // remove the index versions with which v9 will not need to interact
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // remove the index versions with which v9 will not need to interact
|
||||
public static final IndexVersion ZERO = def(0, Version.LATEST);
|
||||
public static final IndexVersion V_7_0_0 = def(7_00_00_99, Version.LUCENE_8_0_0);
|
||||
|
||||
|
@ -222,7 +222,7 @@ public class IndexVersions {
|
|||
return Collections.unmodifiableNavigableMap(builder);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
// We can simplify this once we've removed all references to index versions earlier than MINIMUM_COMPATIBLE
|
||||
static Collection<IndexVersion> getAllVersions() {
|
||||
return VERSION_IDS.values().stream().filter(v -> v.onOrAfter(MINIMUM_COMPATIBLE)).toList();
|
||||
|
|
|
@ -117,7 +117,7 @@ import static org.elasticsearch.index.seqno.SequenceNumbers.UNASSIGNED_SEQ_NO;
|
|||
|
||||
public abstract class Engine implements Closeable {
|
||||
|
||||
@UpdateForV9 // TODO: Remove sync_id in 9.0
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_INDEXING) // TODO: Remove sync_id in 9.0
|
||||
public static final String SYNC_COMMIT_ID = "sync_id";
|
||||
public static final String HISTORY_UUID_KEY = "history_uuid";
|
||||
public static final String FORCE_MERGE_UUID_KEY = "force_merge_uuid";
|
||||
|
|
|
@ -471,7 +471,7 @@ public class ReplicationTracker extends AbstractIndexShardComponent implements L
|
|||
return emptyIfNull(retentionLeases);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_INDEXING)
|
||||
private static RetentionLeases emptyIfNull(RetentionLeases retentionLeases) {
|
||||
// we expect never to see a null in 8.x, so adjust this to throw an exception from v9 onwards.
|
||||
return retentionLeases == null ? RetentionLeases.EMPTY : retentionLeases;
|
||||
|
|
|
@ -541,7 +541,7 @@ class NodeConstruction {
|
|||
return settingsModule;
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_FOUNDATIONS)
|
||||
private static void addBwcSearchWorkerSettings(List<Setting<?>> additionalSettings) {
|
||||
// TODO remove the below settings, they are unused and only here to enable BwC for deployments that still use them
|
||||
additionalSettings.add(
|
||||
|
|
|
@ -27,7 +27,7 @@ class RestCompatibleVersionHelper {
|
|||
/**
|
||||
* @return The requested API version, or {@link Optional#empty()} if there was no explicit version in the request.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
static Optional<RestApiVersion> getCompatibleVersion(
|
||||
@Nullable ParsedMediaType acceptHeader,
|
||||
@Nullable ParsedMediaType contentTypeHeader,
|
||||
|
|
|
@ -47,7 +47,7 @@ public class RestCloseIndexAction extends BaseRestHandler {
|
|||
}
|
||||
|
||||
@Override
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
public RestChannelConsumer prepareRequest(final RestRequest request, final NodeClient client) throws IOException {
|
||||
CloseIndexRequest closeIndexRequest = new CloseIndexRequest(Strings.splitStringByCommaToArray(request.param("index")));
|
||||
closeIndexRequest.masterNodeTimeout(getMasterNodeTimeout(request));
|
||||
|
|
|
@ -52,7 +52,7 @@ import static org.elasticsearch.rest.RestRequest.Method.HEAD;
|
|||
@ServerlessScope(Scope.PUBLIC)
|
||||
public class RestGetAliasesAction extends BaseRestHandler {
|
||||
|
||||
@UpdateForV9 // reject the deprecated ?local parameter
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT) // reject the deprecated ?local parameter
|
||||
private static final DeprecationLogger DEPRECATION_LOGGER = DeprecationLogger.getLogger(RestGetAliasesAction.class);
|
||||
|
||||
@Override
|
||||
|
|
|
@ -34,7 +34,8 @@ public class RestKnnSearchAction extends BaseRestHandler {
|
|||
|
||||
public RestKnnSearchAction() {}
|
||||
|
||||
@UpdateForV9 // these routes were ".deprecated" in RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_RELEVANCE)
|
||||
// these routes were ".deprecated" in RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// this API in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
// Please review and update the code and tests as needed. The original code remains commented out below for reference.
|
||||
|
|
|
@ -33,7 +33,7 @@ import java.util.Map;
|
|||
*
|
||||
* @deprecated Only for 7.x rest compat
|
||||
*/
|
||||
@UpdateForV9 // remove this since it's only for 7.x compat and 7.x compat will be removed in 9.0
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS) // remove this since it's only for 7.x compat and 7.x compat will be removed in 9.0
|
||||
@Deprecated
|
||||
public class MovAvgPipelineAggregationBuilder extends AbstractPipelineAggregationBuilder<MovAvgPipelineAggregationBuilder> {
|
||||
private static final DeprecationLogger deprecationLogger = DeprecationLogger.getLogger(CommonTermsQueryBuilder.class);
|
||||
|
|
|
@ -120,11 +120,11 @@ public class ThreadPool implements ReportingService<ThreadPoolInfo>, Scheduler {
|
|||
|
||||
public enum ThreadPoolType {
|
||||
@Deprecated(forRemoval = true)
|
||||
@UpdateForV9 // no longer used, remove in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // no longer used, remove in v9
|
||||
DIRECT("direct"),
|
||||
FIXED("fixed"),
|
||||
@Deprecated(forRemoval = true)
|
||||
@UpdateForV9 // no longer used, remove in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // no longer used, remove in v9
|
||||
FIXED_AUTO_QUEUE_SIZE("fixed_auto_queue_size"),
|
||||
SCALING("scaling");
|
||||
|
||||
|
|
|
@ -166,7 +166,8 @@ public class TransportStats implements Writeable, ChunkedToXContent {
|
|||
return transportActionStats;
|
||||
}
|
||||
|
||||
@UpdateForV9 // Review and simplify the if-else blocks containing this symbol once v9 is released
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
// Review and simplify the if-else blocks containing this symbol once v9 is released
|
||||
private static final boolean IMPOSSIBLE_IN_V9 = true;
|
||||
|
||||
private boolean assertHistogramsConsistent() {
|
||||
|
@ -181,7 +182,8 @@ public class TransportStats implements Writeable, ChunkedToXContent {
|
|||
}
|
||||
|
||||
@Override
|
||||
@UpdateForV9 // review the "if" blocks checking for non-empty once we have
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
// review the "if" blocks checking for non-empty once we have
|
||||
public Iterator<? extends ToXContent> toXContentChunked(ToXContent.Params outerParams) {
|
||||
return Iterators.concat(Iterators.single((builder, params) -> {
|
||||
builder.startObject(Fields.TRANSPORT);
|
||||
|
|
|
@ -85,7 +85,8 @@ public class TransportGetFeatureUpgradeStatusActionTests extends ESTestCase {
|
|||
.numberOfReplicas(0)
|
||||
.build();
|
||||
|
||||
@UpdateForV9 // Once we start testing 9.x, we should update this test to use a 7.x "version created"
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
// Once we start testing 9.x, we should update this test to use a 7.x "version created"
|
||||
IndexMetadata indexMetadata2 = IndexMetadata.builder(".test-index-2")
|
||||
.settings(Settings.builder().put("index.version.created", TEST_OLD_VERSION).build())
|
||||
.numberOfShards(1)
|
||||
|
|
|
@ -1315,7 +1315,7 @@ public class MetadataCreateIndexServiceTests extends ESTestCase {
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
@AwaitsFix(bugUrl = "looks like a test that's not applicable to 9.0 after version bump")
|
||||
public void testDeprecateTranslogRetentionSettings() {
|
||||
request = new CreateIndexClusterStateUpdateRequest("create index", "test", "test");
|
||||
|
|
|
@ -1977,7 +1977,7 @@ public class MetadataTests extends ESTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
@AwaitsFix(bugUrl = "this test needs to be updated or removed after the version 9.0 bump")
|
||||
public void testSystemAliasValidationMixedVersionSystemAndRegularFails() {
|
||||
final IndexVersion random7xVersion = IndexVersionUtils.randomVersionBetween(
|
||||
|
@ -2029,7 +2029,7 @@ public class MetadataTests extends ESTestCase {
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
@AwaitsFix(bugUrl = "this test needs to be updated or removed after the version 9.0 bump")
|
||||
public void testSystemAliasOldSystemAndNewRegular() {
|
||||
final IndexVersion random7xVersion = IndexVersionUtils.randomVersionBetween(
|
||||
|
@ -2044,7 +2044,7 @@ public class MetadataTests extends ESTestCase {
|
|||
metadataWithIndices(oldVersionSystem, regularIndex);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
@AwaitsFix(bugUrl = "this test needs to be updated or removed after the version 9.0 bump")
|
||||
public void testSystemIndexValidationAllRegular() {
|
||||
final IndexVersion random7xVersion = IndexVersionUtils.randomVersionBetween(
|
||||
|
@ -2060,7 +2060,7 @@ public class MetadataTests extends ESTestCase {
|
|||
metadataWithIndices(currentVersionSystem, currentVersionSystem2, oldVersionSystem);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT)
|
||||
@AwaitsFix(bugUrl = "this test needs to be updated or removed after the version 9.0 bump")
|
||||
public void testSystemAliasValidationAllSystemSomeOld() {
|
||||
final IndexVersion random7xVersion = IndexVersionUtils.randomVersionBetween(
|
||||
|
|
|
@ -116,7 +116,7 @@ public class CompatibleNamedXContentRegistryTests extends ESTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@AwaitsFix(bugUrl = "this can be re-enabled once our rest api version is bumped to V_9")
|
||||
public void testNotCompatibleRequest() throws IOException {
|
||||
NamedXContentRegistry registry = new NamedXContentRegistry(
|
||||
|
|
|
@ -539,7 +539,7 @@ public class NodeEnvironmentTests extends ESTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@AwaitsFix(bugUrl = "test won't work until we remove and bump minimum index versions")
|
||||
public void testIndexCompatibilityChecks() throws IOException {
|
||||
final Settings settings = buildEnvSettings(Settings.EMPTY);
|
||||
|
@ -638,7 +638,7 @@ public class NodeEnvironmentTests extends ESTestCase {
|
|||
env.close();
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@AwaitsFix(bugUrl = "test won't work until we remove and bump minimum index versions")
|
||||
public void testGetBestDowngradeVersion() {
|
||||
assertThat(NodeEnvironment.getBestDowngradeVersion("7.17.0"), Matchers.equalTo("7.17.0"));
|
||||
|
|
|
@ -80,7 +80,7 @@ public class NodeMetadataTests extends ESTestCase {
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@AwaitsFix(bugUrl = "as mentioned in the comment below, the behavior here is changing for 9.0 so this test needs updating")
|
||||
public void testReadsFormatWithoutVersion() throws IOException {
|
||||
// the behaviour tested here is only appropriate if the current version is compatible with versions 7 and earlier
|
||||
|
@ -155,7 +155,7 @@ public class NodeMetadataTests extends ESTestCase {
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@AwaitsFix(bugUrl = "Needs to be updated for 9.0 version bump")
|
||||
public void testUpgradeMarksPreviousVersion() {
|
||||
final String nodeId = randomAlphaOfLength(10);
|
||||
|
|
|
@ -151,7 +151,7 @@ public class IndexVersionTests extends ESTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@AwaitsFix(bugUrl = "believe this fails because index version has not yet been bumped to 9.0")
|
||||
public void testMinimumCompatibleVersion() {
|
||||
assertThat(IndexVersion.getMinimumCompatibleIndexVersion(7170099), equalTo(IndexVersion.fromId(6000099)));
|
||||
|
@ -193,7 +193,7 @@ public class IndexVersionTests extends ESTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@AwaitsFix(bugUrl = "can be unmuted once lucene is bumped to version 10")
|
||||
public void testLuceneVersionOnUnknownVersions() {
|
||||
// between two known versions, should use the lucene version of the previous version
|
||||
|
|
|
@ -578,7 +578,7 @@ public class ParametrizedMapperTests extends MapperServiceTestCase {
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_FOUNDATIONS)
|
||||
@AwaitsFix(bugUrl = "this is testing legacy functionality so can likely be removed in 9.0")
|
||||
public void testDeprecatedParameters() {
|
||||
// 'index' is declared explicitly, 'store' is not, but is one of the previously always-accepted params
|
||||
|
|
|
@ -98,7 +98,7 @@ public class IndicesModuleTests extends ESTestCase {
|
|||
DataStreamTimestampFieldMapper.NAME,
|
||||
FieldNamesFieldMapper.NAME };
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_FOUNDATIONS)
|
||||
@AwaitsFix(bugUrl = "test is referencing 7.x index versions so needs to be updated for 9.0 bump")
|
||||
public void testBuiltinMappers() {
|
||||
IndicesModule module = new IndicesModule(Collections.emptyList());
|
||||
|
|
|
@ -366,7 +366,7 @@ public abstract class AbstractSnapshotIntegTestCase extends ESIntegTestCase {
|
|||
/**
|
||||
* Randomly write an empty snapshot of an older version to an empty repository to simulate an older repository metadata format.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
// This used to pick an index version from 7.0.0 to 8.9.0. The minimum now is 8.0.0 but it's not clear what the upper range should be
|
||||
protected void maybeInitWithOldSnapshotVersion(String repoName, Path repoPath) throws Exception {
|
||||
if (randomBoolean() && randomBoolean()) {
|
||||
|
|
|
@ -1935,7 +1935,7 @@ public abstract class ESRestTestCase extends ESTestCase {
|
|||
* emitted in v8. Note that this message is also permitted in certain YAML test cases, it can be removed there too.
|
||||
* See https://github.com/elastic/elasticsearch/issues/66419 for more details.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
private static final String WAIT_FOR_ACTIVE_SHARDS_DEFAULT_DEPRECATION_MESSAGE = "the default value for the ?wait_for_active_shards "
|
||||
+ "parameter will change from '0' to 'index-setting' in version 8; specify '?wait_for_active_shards=index-setting' "
|
||||
+ "to adopt the future default behaviour, or '?wait_for_active_shards=0' to preserve today's behaviour";
|
||||
|
|
|
@ -26,23 +26,23 @@ import static org.elasticsearch.cluster.ClusterState.VERSION_INTRODUCING_TRANSPO
|
|||
*/
|
||||
public class RestTestLegacyFeatures implements FeatureSpecification {
|
||||
public static final NodeFeature ML_STATE_RESET_FALLBACK_ON_DISABLED = new NodeFeature("ml.state_reset_fallback_on_disabled");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature FEATURE_STATE_RESET_SUPPORTED = new NodeFeature("system_indices.feature_state_reset_supported");
|
||||
public static final NodeFeature SYSTEM_INDICES_REST_ACCESS_ENFORCED = new NodeFeature("system_indices.rest_access_enforced");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SYSTEM_INDICES_REST_ACCESS_DEPRECATED = new NodeFeature("system_indices.rest_access_deprecated");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature HIDDEN_INDICES_SUPPORTED = new NodeFeature("indices.hidden_supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature COMPONENT_TEMPLATE_SUPPORTED = new NodeFeature("indices.component_template_supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature DELETE_TEMPLATE_MULTIPLE_NAMES_SUPPORTED = new NodeFeature(
|
||||
"indices.delete_template_multiple_names_supported"
|
||||
);
|
||||
public static final NodeFeature ML_NEW_MEMORY_FORMAT = new NodeFeature("ml.new_memory_format");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SUPPORTS_VENDOR_XCONTENT_TYPES = new NodeFeature("rest.supports_vendor_xcontent_types");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SUPPORTS_TRUE_BINARY_RESPONSES = new NodeFeature("rest.supports_true_binary_responses");
|
||||
|
||||
/** These are "pure test" features: normally we would not need them, and test for TransportVersion/fallback to Version (see for example
|
||||
|
@ -61,20 +61,20 @@ public class RestTestLegacyFeatures implements FeatureSpecification {
|
|||
public static final NodeFeature DESIRED_NODE_API_SUPPORTED = new NodeFeature("desired_node_supported");
|
||||
public static final NodeFeature SECURITY_UPDATE_API_KEY = new NodeFeature("security.api_key_update");
|
||||
public static final NodeFeature SECURITY_BULK_UPDATE_API_KEY = new NodeFeature("security.api_key_bulk_update");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature WATCHES_VERSION_IN_META = new NodeFeature("watcher.version_in_meta");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SECURITY_ROLE_DESCRIPTORS_OPTIONAL = new NodeFeature("security.role_descriptors_optional");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SEARCH_AGGREGATIONS_FORCE_INTERVAL_SELECTION_DATE_HISTOGRAM = new NodeFeature(
|
||||
"search.aggregations.force_interval_selection_on_date_histogram"
|
||||
);
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature TRANSFORM_NEW_API_ENDPOINT = new NodeFeature("transform.new_api_endpoint");
|
||||
// Ref: https://github.com/elastic/elasticsearch/pull/65205
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature ML_INDICES_HIDDEN = new NodeFeature("ml.indices_hidden");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature ML_ANALYTICS_MAPPINGS = new NodeFeature("ml.analytics_mappings");
|
||||
|
||||
public static final NodeFeature TSDB_NEW_INDEX_FORMAT = new NodeFeature("indices.tsdb_new_format");
|
||||
|
@ -101,29 +101,29 @@ public class RestTestLegacyFeatures implements FeatureSpecification {
|
|||
public static final NodeFeature DEPRECATION_WARNINGS_LEAK_FIXED = new NodeFeature("deprecation_warnings_leak_fixed");
|
||||
|
||||
// QA - Full cluster restart
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature REPLICATION_OF_CLOSED_INDICES = new NodeFeature("indices.closed_replication_supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature TASK_INDEX_SYSTEM_INDEX = new NodeFeature("tasks.moved_to_system_index");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SOFT_DELETES_ENFORCED = new NodeFeature("indices.soft_deletes_enforced");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature NEW_TRANSPORT_COMPRESSED_SETTING = new NodeFeature("transport.new_compressed_setting");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SHUTDOWN_SUPPORTED = new NodeFeature("shutdown.supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SERVICE_ACCOUNTS_SUPPORTED = new NodeFeature("auth.service_accounts_supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature TRANSFORM_SUPPORTED = new NodeFeature("transform.supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature SLM_SUPPORTED = new NodeFeature("slm.supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature DATA_STREAMS_SUPPORTED = new NodeFeature("data_stream.supported");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature NEW_DATA_STREAMS_INDEX_NAME_FORMAT = new NodeFeature("data_stream.new_index_name_format");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature DISABLE_FIELD_NAMES_FIELD_REMOVED = new NodeFeature("disable_of_field_names_field_removed");
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static final NodeFeature ML_NLP_SUPPORTED = new NodeFeature("ml.nlp_supported");
|
||||
|
||||
/*
|
||||
|
|
|
@ -641,7 +641,7 @@ public class MockTransportService extends TransportService {
|
|||
// into a different class that cannot be re-serialized (i.e. JOIN_VALIDATE_ACTION_NAME),
|
||||
// in those cases we just copy the raw bytes back to a BytesTransportRequest.
|
||||
// This is only needed for the BwC for JOIN_VALIDATE_ACTION_NAME and can be removed in the next major
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
private static TransportRequest copyRawBytesForBwC(BytesStreamOutput bStream) throws IOException {
|
||||
return new BytesTransportRequest(bStream.bytes().streamInput());
|
||||
}
|
||||
|
|
|
@ -240,7 +240,7 @@ public abstract class ESClientYamlSuiteTestCase extends ESRestTestCase {
|
|||
* Enables support for parsing the legacy version-based node_selector format.
|
||||
*/
|
||||
@Deprecated
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
public static Iterable<Object[]> createParametersWithLegacyNodeSelectorSupport() throws Exception {
|
||||
var executableSectionRegistry = new NamedXContentRegistry(
|
||||
Stream.concat(
|
||||
|
|
|
@ -87,7 +87,7 @@ public class DoSection implements ExecutableSection {
|
|||
return parse(parser, false);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
@Deprecated
|
||||
public static DoSection parseWithLegacyNodeSelectorSupport(XContentParser parser) throws IOException {
|
||||
return parse(parser, true);
|
||||
|
@ -374,7 +374,7 @@ public class DoSection implements ExecutableSection {
|
|||
// #84038 and #84089 mean that this assertion fails when running against < 7.17.2 and 8.0.0 released versions
|
||||
// This is really difficult to express just with features, so I will break it down into 2 parts: version check for v7,
|
||||
// and feature check for v8. This way the version check can be removed once we move to v9
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
var fixedInV7 = executionContext.clusterHasFeature("gte_v7.17.2", false)
|
||||
&& executionContext.clusterHasFeature("gte_v8.0.0", false) == false;
|
||||
var fixedProductionHeader = fixedInV7
|
||||
|
|
|
@ -328,7 +328,7 @@ public class PrerequisiteSection {
|
|||
parser.nextToken();
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
|
||||
private static boolean parseRestCompatVersion(XContentParser parser, PrerequisiteSectionBuilder builder) throws IOException {
|
||||
// allow skip version only for v7 REST compatibility tests, to be removed for V9
|
||||
if ("true".equals(System.getProperty("tests.restCompat"))) return parseString(parser, builder::skipIfVersion);
|
||||
|
|
|
@ -580,7 +580,7 @@ public class DoSectionTests extends AbstractClientYamlTestFragmentParserTestCase
|
|||
assertThat(e.getMessage(), equalTo("the warning [foo] was both allowed and expected"));
|
||||
}
|
||||
|
||||
@UpdateForV9 // remove
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // remove
|
||||
public void testLegacyNodeSelectorByVersionRange() throws IOException {
|
||||
parser = createParser(YamlXContent.yamlXContent, """
|
||||
node_selector:
|
||||
|
|
|
@ -1813,7 +1813,7 @@ public class AutoFollowCoordinatorTests extends ESTestCase {
|
|||
assertThat(counter.get(), equalTo(states.length));
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
@AwaitsFix(bugUrl = "ability to disable soft deletes was removed in 8.0 indexes so we can probably remove this test")
|
||||
public void testAutoFollowerSoftDeletesDisabled() {
|
||||
Client client = mock(Client.class);
|
||||
|
|
|
@ -56,7 +56,7 @@ public class Phase implements ToXContentObject, Writeable {
|
|||
// when the phase is read from the cluster state during startup (even before negative timevalues were strictly
|
||||
// disallowed) so this is a hack to treat negative `min_age`s as 0 to prevent those errors.
|
||||
// They will be saved as `0` so this hack can be removed once we no longer have to read cluster states from 7.x.
|
||||
@UpdateForV9 // remove this hack now that we don't have to read 7.x cluster states
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT) // remove this hack now that we don't have to read 7.x cluster states
|
||||
final String timeValueString = p.text();
|
||||
if (timeValueString.startsWith("-")) {
|
||||
logger.warn("phase has negative min_age value of [{}] - this will be treated as a min_age of 0", timeValueString);
|
||||
|
|
|
@ -40,7 +40,7 @@ public class GetSecuritySettingsAction {
|
|||
super(masterNodeTimeout);
|
||||
}
|
||||
|
||||
@UpdateForV9 // no need for bwc any more, this can be inlined
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SECURITY) // no need for bwc any more, this can be inlined
|
||||
public static Request readFrom(StreamInput in) throws IOException {
|
||||
if (in.getTransportVersion().onOrAfter(TransportVersions.SECURITY_SETTINGS_REQUEST_TIMEOUTS)) {
|
||||
return new Request(in);
|
||||
|
|
|
@ -116,7 +116,7 @@ public class UpdateSecuritySettingsAction {
|
|||
this.profilesIndexSettings = Objects.requireNonNullElse(profilesIndexSettings, Collections.emptyMap());
|
||||
}
|
||||
|
||||
@UpdateForV9 // no need for bwc any more, this can be inlined
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SECURITY) // no need for bwc any more, this can be inlined
|
||||
public static Request readFrom(StreamInput in) throws IOException {
|
||||
if (in.getTransportVersion().onOrAfter(TransportVersions.SECURITY_SETTINGS_REQUEST_TIMEOUTS)) {
|
||||
return new Request(in);
|
||||
|
|
|
@ -59,7 +59,7 @@ public class UpdateWatcherSettingsAction extends ActionType<AcknowledgedResponse
|
|||
this.settings = in.readGenericMap();
|
||||
}
|
||||
|
||||
@UpdateForV9 // bwc no longer required
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DATA_MANAGEMENT) // bwc no longer required
|
||||
private Request(TimeValue masterNodeTimeout, TimeValue ackTimeout, StreamInput in) throws IOException {
|
||||
super(masterNodeTimeout, ackTimeout);
|
||||
this.settings = in.readGenericMap();
|
||||
|
|
|
@ -32,7 +32,7 @@ public class NodesDeprecationCheckAction extends ActionType<NodesDeprecationChec
|
|||
super(NAME);
|
||||
}
|
||||
|
||||
@UpdateForV9 // this can be replaced with TransportRequest.Empty in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // this can be replaced with TransportRequest.Empty in v9
|
||||
public static class NodeRequest extends TransportRequest {
|
||||
|
||||
public NodeRequest() {}
|
||||
|
|
|
@ -26,7 +26,7 @@ import java.util.List;
|
|||
import static org.elasticsearch.Version.V_8_12_0;
|
||||
import static org.hamcrest.Matchers.greaterThanOrEqualTo;
|
||||
|
||||
@UpdateForV9 // Investigate what needs to be added in terms of 9.0 migration testing
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.ENTERPRISE_SEARCH) // Investigate what needs to be added in terms of 9.0 migration testing
|
||||
public class FullClusterRestartIT extends ParameterizedFullClusterRestartTestCase {
|
||||
// DSL was introduced with version 8.12.0 of ES.
|
||||
private static final Version DSL_DEFAULT_RETENTION_VERSION = V_8_12_0;
|
||||
|
|
|
@ -38,7 +38,7 @@ public final class RestFreezeIndexAction extends BaseRestHandler {
|
|||
private static final String UNFREEZE_DEPRECATED = "Frozen indices are deprecated because they provide no benefit given improvements "
|
||||
+ "in heap memory utilization. They will be removed in a future release.";
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_INDEXING)
|
||||
// these routes were ".deprecated" in RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// this API in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
|
|
|
@ -87,7 +87,7 @@ public class TransportTrainedModelCacheInfoAction extends TransportNodesAction<
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9 // this can be replaced with TransportRequest.Empty in v9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING) // this can be replaced with TransportRequest.Empty in v9
|
||||
public static class NodeModelCacheInfoRequest extends TransportRequest {
|
||||
|
||||
NodeModelCacheInfoRequest() {}
|
||||
|
|
|
@ -28,7 +28,7 @@ import static org.elasticsearch.xpack.ml.MachineLearning.BASE_PATH;
|
|||
@ServerlessScope(Scope.PUBLIC)
|
||||
public class RestDeleteTrainedModelAction extends BaseRestHandler {
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING)
|
||||
// one or more routes use ".replaces" with RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// that route in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
|
|
|
@ -49,7 +49,7 @@ public class RestGetTrainedModelsAction extends BaseRestHandler {
|
|||
private static final DeprecationLogger deprecationLogger = DeprecationLogger.getLogger(RestGetTrainedModelsAction.class);
|
||||
private static final String INCLUDE_MODEL_DEFINITION = "include_model_definition";
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING)
|
||||
// one or more routes use ".replaces" with RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// that route in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
|
|
|
@ -30,7 +30,7 @@ import static org.elasticsearch.xpack.ml.MachineLearning.BASE_PATH;
|
|||
@ServerlessScope(Scope.PUBLIC)
|
||||
public class RestGetTrainedModelsStatsAction extends BaseRestHandler {
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING)
|
||||
// one or more routes use ".replaces" with RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// that route in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
|
|
|
@ -37,7 +37,8 @@ public class RestInferTrainedModelDeploymentAction extends BaseRestHandler {
|
|||
return "xpack_ml_infer_trained_models_deployment_action";
|
||||
}
|
||||
|
||||
@UpdateForV9 // these routes were ".deprecated" in RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING)
|
||||
// these routes were ".deprecated" in RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// this API in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
// Please review and update the code and tests as needed. The original code remains commented out below for reference.
|
||||
|
|
|
@ -27,7 +27,7 @@ import static org.elasticsearch.xpack.ml.MachineLearning.BASE_PATH;
|
|||
@ServerlessScope(Scope.PUBLIC)
|
||||
public class RestPutTrainedModelAction extends BaseRestHandler {
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING)
|
||||
// one or more routes use ".replaces" with RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// that route in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
|
|
|
@ -28,7 +28,8 @@ public class RestPostDataAction extends BaseRestHandler {
|
|||
private static final String DEFAULT_RESET_START = "";
|
||||
private static final String DEFAULT_RESET_END = "";
|
||||
|
||||
@UpdateForV9 // these routes were ".deprecated" in RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING)
|
||||
// these routes were ".deprecated" in RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// this API in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
// Please review and update the code and tests as needed. The original code remains commented out below for reference.
|
||||
|
|
|
@ -17,7 +17,7 @@ public class OldCodecsAvailableTests extends ESTestCase {
|
|||
* Reminder to add Lucene BWC codecs under {@link org.elasticsearch.xpack.lucene.bwc.codecs} whenever Elasticsearch is upgraded
|
||||
* to the next major Lucene version.
|
||||
*/
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_FOUNDATIONS)
|
||||
@AwaitsFix(bugUrl = "muted until we add bwc codecs as part of lucene 10 upgrade")
|
||||
public void testLuceneBWCCodecsAvailable() {
|
||||
assertEquals("Add Lucene BWC codecs for Elasticsearch version 7", 8, Version.CURRENT.major);
|
||||
|
|
|
@ -54,7 +54,7 @@ final class CO2Calculator {
|
|||
return getKiloWattsPerCore(host) * getCO2TonsPerKWH(host) * annualCoreHours * getDatacenterPUE(host);
|
||||
}
|
||||
|
||||
@UpdateForV9 // only allow OTEL semantic conventions
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // only allow OTEL semantic conventions
|
||||
private double getKiloWattsPerCore(HostMetadata host) {
|
||||
return switch (host.hostArchitecture) {
|
||||
// For the OTEL donation of the profiling agent, we switch to OTEL semantic conventions,
|
||||
|
|
|
@ -25,9 +25,9 @@ public class GetFlamegraphResponse extends ActionResponse implements ChunkedToXC
|
|||
private final int size;
|
||||
private final double samplingRate;
|
||||
private final long selfCPU;
|
||||
@UpdateForV9 // remove this field - it is unused in Kibana
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // remove this field - it is unused in Kibana
|
||||
private final long totalCPU;
|
||||
@UpdateForV9 // remove this field - it is unused in Kibana
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // remove this field - it is unused in Kibana
|
||||
private final long totalSamples;
|
||||
private final List<Map<String, Integer>> edges;
|
||||
private final List<String> fileIds;
|
||||
|
@ -173,7 +173,7 @@ public class GetFlamegraphResponse extends ActionResponse implements ChunkedToXC
|
|||
return totalSamples;
|
||||
}
|
||||
|
||||
@UpdateForV9 // change casing from Camel Case to Snake Case (requires updates in Kibana as well)
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // change casing from Camel Case to Snake Case (requires updates in Kibana as well)
|
||||
@Override
|
||||
public Iterator<? extends ToXContent> toXContentChunked(ToXContent.Params params) {
|
||||
return Iterators.concat(
|
||||
|
|
|
@ -43,7 +43,7 @@ public class GetStackTracesRequest extends ActionRequest implements IndicesReque
|
|||
public static final ParseField LIMIT_FIELD = new ParseField("limit");
|
||||
public static final ParseField INDICES_FIELD = new ParseField("indices");
|
||||
public static final ParseField STACKTRACE_IDS_FIELD = new ParseField("stacktrace_ids_field");
|
||||
@UpdateForV9 // Remove this BWC layer and allow only AGGREGATION_FIELDS
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // Remove this BWC layer and allow only AGGREGATION_FIELDS
|
||||
public static final ParseField AGGREGATION_FIELD = new ParseField("aggregation_field");
|
||||
public static final ParseField AGGREGATION_FIELDS = new ParseField("aggregation_fields");
|
||||
public static final ParseField REQUESTED_DURATION_FIELD = new ParseField("requested_duration");
|
||||
|
@ -62,7 +62,7 @@ public class GetStackTracesRequest extends ActionRequest implements IndicesReque
|
|||
private String[] indices;
|
||||
private boolean userProvidedIndices;
|
||||
private String stackTraceIdsField;
|
||||
@UpdateForV9 // Remove this BWC layer and allow only aggregationFields
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // Remove this BWC layer and allow only aggregationFields
|
||||
private String aggregationField;
|
||||
private String[] aggregationFields;
|
||||
private Double requestedDuration;
|
||||
|
|
|
@ -30,10 +30,10 @@ public class GetStackTracesResponse extends ActionResponse implements ChunkedToX
|
|||
private final Map<String, StackFrame> stackFrames;
|
||||
@Nullable
|
||||
private final Map<String, String> executables;
|
||||
@UpdateForV9 // remove this field - it is unused in Kibana
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // remove this field - it is unused in Kibana
|
||||
@Nullable
|
||||
private final Map<String, TraceEvent> stackTraceEvents;
|
||||
@UpdateForV9 // remove this field - it is unused in Kibana
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // remove this field - it is unused in Kibana
|
||||
private final int totalFrames;
|
||||
private final double samplingRate;
|
||||
private final long totalSamples;
|
||||
|
|
|
@ -31,7 +31,8 @@ final class HostMetadata implements ToXContentObject {
|
|||
this.profilingNumCores = profilingNumCores != null ? profilingNumCores : DEFAULT_PROFILING_NUM_CORES;
|
||||
}
|
||||
|
||||
@UpdateForV9 // remove fallback to the "profiling.host.machine" field and remove it from the component template "profiling-hosts".
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING)
|
||||
// remove fallback to the "profiling.host.machine" field and remove it from the component template "profiling-hosts".
|
||||
public static HostMetadata fromSource(Map<String, Object> source) {
|
||||
if (source != null) {
|
||||
String hostID = (String) source.get("host.id");
|
||||
|
|
|
@ -74,7 +74,7 @@ final class InstanceType implements ToXContentObject {
|
|||
return new InstanceType(provider, region, null);
|
||||
}
|
||||
|
||||
@UpdateForV9 // remove this method
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // remove this method
|
||||
private static InstanceType fromObsoleteHostSource(Map<String, Object> source) {
|
||||
// Check and handle AWS.
|
||||
String region = (String) source.get("ec2.placement.region");
|
||||
|
|
|
@ -19,7 +19,7 @@ import java.util.Objects;
|
|||
public class SubGroup implements ToXContentFragment {
|
||||
private final String name;
|
||||
private Long count;
|
||||
@UpdateForV9 // remove legacy XContent rendering
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.PROFILING) // remove legacy XContent rendering
|
||||
private final boolean renderLegacyXContent;
|
||||
private final Map<String, SubGroup> subgroups;
|
||||
|
||||
|
|
|
@ -28,7 +28,8 @@ public class SearchableSnapshotEnableAllocationDecider extends AllocationDecider
|
|||
* ongoing is determined by cluster.routing.allocation.enable=primaries. Notice that other values for that setting except "all" mean
|
||||
* that no searchable snapshots are allocated anyway.
|
||||
*/
|
||||
@UpdateForV9 // xpack.searchable.snapshot.allocate_on_rolling_restart was only temporary, remove it in the next major
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
// xpack.searchable.snapshot.allocate_on_rolling_restart was only temporary, remove it in the next major
|
||||
public static final Setting<Boolean> SEARCHABLE_SNAPSHOTS_ALLOCATE_ON_ROLLING_RESTART = Setting.boolSetting(
|
||||
"xpack.searchable.snapshot.allocate_on_rolling_restart",
|
||||
false,
|
||||
|
|
|
@ -60,7 +60,8 @@ public class CachedBlob implements ToXContent {
|
|||
|
||||
@Override
|
||||
public XContentBuilder toXContent(XContentBuilder builder, Params params) throws IOException {
|
||||
@UpdateForV9 // we can remove the version field when we no longer need to keep compatibility with <8.12
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_FOUNDATIONS)
|
||||
// we can remove the version field when we no longer need to keep compatibility with <8.12
|
||||
final int version = Version.CURRENT.id;
|
||||
builder.startObject();
|
||||
{
|
||||
|
|
|
@ -29,7 +29,7 @@ import static org.hamcrest.Matchers.not;
|
|||
import static org.hamcrest.Matchers.notNullValue;
|
||||
import static org.hamcrest.Matchers.sameInstance;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
@LuceneTestCase.AwaitsFix(bugUrl = "this testing a number of pre 8.0 upgrade scenarios so needs updating or removal for 9.0")
|
||||
public class SearchableSnapshotIndexMetadataUpgraderTests extends ESTestCase {
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@ import static org.mockito.Mockito.mock;
|
|||
|
||||
public class SecurityImplicitBehaviorBootstrapCheckTests extends AbstractBootstrapCheckTestCase {
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SECURITY)
|
||||
@AwaitsFix(bugUrl = "requires updates for version 9.0 bump")
|
||||
public void testUpgradeFrom8xWithImplicitSecuritySettings() throws Exception {
|
||||
final BuildVersion previousVersion = toBuildVersion(VersionUtils.randomVersionBetween(random(), Version.V_8_0_0, null));
|
||||
|
@ -46,7 +46,7 @@ public class SecurityImplicitBehaviorBootstrapCheckTests extends AbstractBootstr
|
|||
assertThat(result.isSuccess(), is(true));
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SECURITY)
|
||||
@AwaitsFix(bugUrl = "requires updates for version 9.0 bump")
|
||||
public void testUpgradeFrom8xWithExplicitSecuritySettings() throws Exception {
|
||||
final BuildVersion previousVersion = toBuildVersion(VersionUtils.randomVersionBetween(random(), Version.V_8_0_0, null));
|
||||
|
|
|
@ -90,7 +90,7 @@ public class FullClusterRestartIT extends ParameterizedFullClusterRestartTestCas
|
|||
|
||||
@Before
|
||||
public void checkClusterVersion() {
|
||||
@UpdateForV9 // always true
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA) // always true
|
||||
var originalClusterSupportsShutdown = oldClusterHasFeature(RestTestLegacyFeatures.SHUTDOWN_SUPPORTED);
|
||||
assumeTrue("no shutdown in versions before 7.15", originalClusterSupportsShutdown);
|
||||
}
|
||||
|
|
|
@ -203,7 +203,7 @@ public class SnapshotsRecoveryPlannerServiceTests extends ESTestCase {
|
|||
});
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
@AwaitsFix(bugUrl = "this is testing pre-7.0 upgrade behavior so probably needs some updating")
|
||||
public void testLogicallyEquivalentSnapshotIsUsedEvenIfFilesAreDifferent() throws Exception {
|
||||
createStore(store -> {
|
||||
|
@ -390,7 +390,7 @@ public class SnapshotsRecoveryPlannerServiceTests extends ESTestCase {
|
|||
});
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.DISTRIBUTED_COORDINATION)
|
||||
@AwaitsFix(bugUrl = "this is testing v7.14 compat functionality so can probably be removed")
|
||||
public void testFallbacksToSourceOnlyPlanIfTargetNodeIsInUnsupportedVersion() throws Exception {
|
||||
createStore(store -> {
|
||||
|
|
|
@ -22,7 +22,7 @@ import java.io.IOException;
|
|||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@LuceneTestCase.AwaitsFix(bugUrl = "this is testing legacy functionality so can likely be removed in 9.0")
|
||||
public class GeoBoundingBoxQueryLegacyGeoShapeWithDocValuesIT extends GeoBoundingBoxQueryIntegTestCase {
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ import static org.elasticsearch.test.hamcrest.ElasticsearchAssertions.assertAcke
|
|||
import static org.elasticsearch.test.hamcrest.ElasticsearchAssertions.assertHitCount;
|
||||
import static org.hamcrest.Matchers.containsString;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@LuceneTestCase.AwaitsFix(bugUrl = "this is testing legacy functionality so can likely be removed in 9.0")
|
||||
public class LegacyGeoShapeWithDocValuesIT extends GeoShapeIntegTestCase {
|
||||
|
||||
|
|
|
@ -280,7 +280,7 @@ public class GeoShapeWithDocValuesFieldMapperTests extends GeoFieldMapperTests {
|
|||
);
|
||||
}
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@AwaitsFix(bugUrl = "this is testing legacy functionality so can likely be removed in 9.0")
|
||||
public void testGeoShapeLegacyMerge() throws Exception {
|
||||
IndexVersion version = IndexVersionUtils.randomPreviousCompatibleVersion(random(), IndexVersions.V_8_0_0);
|
||||
|
|
|
@ -41,7 +41,7 @@ import static org.elasticsearch.test.hamcrest.ElasticsearchAssertions.assertHitC
|
|||
import static org.elasticsearch.xcontent.XContentFactory.jsonBuilder;
|
||||
import static org.hamcrest.Matchers.containsString;
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.SEARCH_ANALYTICS)
|
||||
@LuceneTestCase.AwaitsFix(bugUrl = "this is testing legacy functionality so can likely be removed in 9.0")
|
||||
public class LegacyGeoShapeWithDocValuesQueryTests extends GeoShapeQueryTestCase {
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ import static org.elasticsearch.xpack.textstructure.TextStructurePlugin.BASE_PAT
|
|||
@ServerlessScope(Scope.INTERNAL)
|
||||
public class RestFindStructureAction extends BaseRestHandler {
|
||||
|
||||
@UpdateForV9
|
||||
@UpdateForV9(owner = UpdateForV9.Owner.MACHINE_LEARNING)
|
||||
// one or more routes use ".replaces" with RestApiVersion.V_8 which will require use of REST API compatibility headers to access
|
||||
// that route in v9. It is unclear if this was intentional for v9, and the code has been updated to ".deprecateAndKeep" which will
|
||||
// continue to emit deprecations warnings but will not require any special headers to access the API in v9.
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue