diff --git a/docs/build.gradle b/docs/build.gradle
index 7f490e7de81e6..91c6cbb3ba3ef 100644
--- a/docs/build.gradle
+++ b/docs/build.gradle
@@ -54,10 +54,6 @@ testClusters.matching { it.name == "integTest"}.configureEach {
if (singleNode().testDistribution == DEFAULT) {
setting 'xpack.license.self_generated.type', 'trial'
setting 'indices.lifecycle.history_index_enabled', 'false'
- if (BuildParams.isSnapshotBuild() == false) {
- systemProperty 'es.autoscaling_feature_flag_registered', 'true'
- }
- setting 'xpack.autoscaling.enabled', 'true'
systemProperty 'es.rollup_v2_feature_flag_enabled', 'true'
keystorePassword 's3cr3t'
}
diff --git a/docs/reference/autoscaling/apis/autoscaling-apis.asciidoc b/docs/reference/autoscaling/apis/autoscaling-apis.asciidoc
index f153d93decfa7..2dd765e746682 100644
--- a/docs/reference/autoscaling/apis/autoscaling-apis.asciidoc
+++ b/docs/reference/autoscaling/apis/autoscaling-apis.asciidoc
@@ -3,6 +3,8 @@
[[autoscaling-apis]]
== Autoscaling APIs
+experimental[]
+
You can use the following APIs to perform autoscaling operations.
[discrete]
diff --git a/docs/reference/autoscaling/apis/delete-autoscaling-policy.asciidoc b/docs/reference/autoscaling/apis/delete-autoscaling-policy.asciidoc
index 5f06c85587c78..1bcf2a0d935a8 100644
--- a/docs/reference/autoscaling/apis/delete-autoscaling-policy.asciidoc
+++ b/docs/reference/autoscaling/apis/delete-autoscaling-policy.asciidoc
@@ -6,6 +6,8 @@
Delete autoscaling policy
++++
+experimental[]
+
Delete autoscaling policy.
[[autoscaling-delete-autoscaling-policy-request]]
diff --git a/docs/reference/autoscaling/apis/get-autoscaling-capacity.asciidoc b/docs/reference/autoscaling/apis/get-autoscaling-capacity.asciidoc
index 24331bbe8b83e..ae359fd81d220 100644
--- a/docs/reference/autoscaling/apis/get-autoscaling-capacity.asciidoc
+++ b/docs/reference/autoscaling/apis/get-autoscaling-capacity.asciidoc
@@ -6,6 +6,8 @@
Get autoscaling capacity
++++
+experimental[]
+
Get autoscaling capacity.
[[autoscaling-get-autoscaling-capacity-request]]
diff --git a/docs/reference/autoscaling/apis/get-autoscaling-policy.asciidoc b/docs/reference/autoscaling/apis/get-autoscaling-policy.asciidoc
index d78528ad37860..6ca04f3ab6f3b 100644
--- a/docs/reference/autoscaling/apis/get-autoscaling-policy.asciidoc
+++ b/docs/reference/autoscaling/apis/get-autoscaling-policy.asciidoc
@@ -6,6 +6,8 @@
Get autoscaling policy
++++
+experimental[]
+
Get autoscaling policy.
[[autoscaling-get-autoscaling-policy-request]]
diff --git a/docs/reference/autoscaling/apis/put-autoscaling-policy.asciidoc b/docs/reference/autoscaling/apis/put-autoscaling-policy.asciidoc
index 30418489570e6..9131983715e6c 100644
--- a/docs/reference/autoscaling/apis/put-autoscaling-policy.asciidoc
+++ b/docs/reference/autoscaling/apis/put-autoscaling-policy.asciidoc
@@ -6,6 +6,8 @@
Put autoscaling policy
++++
+experimental[]
+
Put autoscaling policy.
[[autoscaling-put-autoscaling-policy-request]]
diff --git a/docs/reference/index.asciidoc b/docs/reference/index.asciidoc
index 1e39636c3192b..1c1c19cedc57c 100644
--- a/docs/reference/index.asciidoc
+++ b/docs/reference/index.asciidoc
@@ -48,12 +48,8 @@ include::data-management.asciidoc[]
include::ilm/index.asciidoc[]
-ifdef::permanently-unreleased-branch[]
-
include::autoscaling/index.asciidoc[]
-endif::[]
-
include::monitoring/index.asciidoc[]
include::frozen-indices.asciidoc[]
diff --git a/docs/reference/rest-api/index.asciidoc b/docs/reference/rest-api/index.asciidoc
index 0b2e839888d76..24771051bd741 100644
--- a/docs/reference/rest-api/index.asciidoc
+++ b/docs/reference/rest-api/index.asciidoc
@@ -11,9 +11,7 @@ We are working on including more {es} APIs in this section. Some content might
not be included yet.
* <>
-ifdef::permanently-unreleased-branch[]
* <>
-endif::[]
* <>
* <>
* <>
@@ -43,9 +41,7 @@ endif::[]
--
include::{es-repo-dir}/api-conventions.asciidoc[]
-ifdef::permanently-unreleased-branch[]
include::{es-repo-dir}/autoscaling/apis/autoscaling-apis.asciidoc[]
-endif::[]
include::{es-repo-dir}/cat.asciidoc[]
include::{es-repo-dir}/cluster.asciidoc[]
include::{es-repo-dir}/ccr/apis/ccr-apis.asciidoc[]
diff --git a/x-pack/plugin/autoscaling/build.gradle b/x-pack/plugin/autoscaling/build.gradle
index 12b91ded97eba..b8cadf5b2c9ab 100644
--- a/x-pack/plugin/autoscaling/build.gradle
+++ b/x-pack/plugin/autoscaling/build.gradle
@@ -12,15 +12,9 @@ esplugin {
}
archivesBaseName = 'x-pack-autoscaling'
-tasks.named('internalClusterTest').configure {
- if (BuildParams.isSnapshotBuild() == false) {
- systemProperty 'es.autoscaling_feature_flag_registered', 'true'
- }
-}
-
dependencies {
compileOnly project(path: xpackModule('core'), configuration: 'default')
testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts')
}
-addQaCheckDependencies()
\ No newline at end of file
+addQaCheckDependencies()
diff --git a/x-pack/plugin/autoscaling/qa/rest/build.gradle b/x-pack/plugin/autoscaling/qa/rest/build.gradle
index bdfa4886ab961..ccd276b45a7e7 100644
--- a/x-pack/plugin/autoscaling/qa/rest/build.gradle
+++ b/x-pack/plugin/autoscaling/qa/rest/build.gradle
@@ -15,10 +15,6 @@ restResources {
testClusters.all {
testDistribution = 'DEFAULT'
- if (BuildParams.isSnapshotBuild() == false) {
- systemProperty 'es.autoscaling_feature_flag_registered', 'true'
- }
- setting 'xpack.autoscaling.enabled', 'true'
setting 'xpack.security.enabled', 'true'
extraConfigFile 'roles.yml', file('autoscaling-roles.yml')
user username: 'autoscaling-admin', password: 'autoscaling-admin-password', role: 'superuser'
diff --git a/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/AutoscalingIntegTestCase.java b/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/AutoscalingIntegTestCase.java
index 359f806900329..84dbb0f3b6937 100644
--- a/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/AutoscalingIntegTestCase.java
+++ b/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/AutoscalingIntegTestCase.java
@@ -6,7 +6,6 @@
package org.elasticsearch.xpack.autoscaling;
-import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.plugins.Plugin;
import org.elasticsearch.test.ESIntegTestCase;
@@ -19,12 +18,4 @@ public abstract class AutoscalingIntegTestCase extends ESIntegTestCase {
protected Collection> nodePlugins() {
return List.of(LocalStateAutoscaling.class);
}
-
- @Override
- protected Settings nodeSettings(final int nodeOrdinal) {
- final Settings.Builder builder = Settings.builder().put(super.nodeSettings(nodeOrdinal));
- builder.put(Autoscaling.AUTOSCALING_ENABLED_SETTING.getKey(), true);
- return builder.build();
- }
-
}
diff --git a/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/storage/ReactiveStorageIT.java b/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/storage/ReactiveStorageIT.java
index af27aa2b2f68b..a441bb50d4c96 100644
--- a/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/storage/ReactiveStorageIT.java
+++ b/x-pack/plugin/autoscaling/src/internalClusterTest/java/org/elasticsearch/xpack/autoscaling/storage/ReactiveStorageIT.java
@@ -20,7 +20,6 @@
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.plugins.Plugin;
import org.elasticsearch.test.ESIntegTestCase;
-import org.elasticsearch.xpack.autoscaling.Autoscaling;
import org.elasticsearch.xpack.autoscaling.LocalStateAutoscaling;
import org.elasticsearch.xpack.autoscaling.action.GetAutoscalingCapacityAction;
import org.elasticsearch.xpack.autoscaling.action.PutAutoscalingPolicyAction;
@@ -55,8 +54,7 @@ protected Collection> nodePlugins() {
@Override
protected Settings nodeSettings(final int nodeOrdinal) {
final Settings.Builder builder = Settings.builder().put(super.nodeSettings(nodeOrdinal));
- builder.put(Autoscaling.AUTOSCALING_ENABLED_SETTING.getKey(), true)
- .put(DiskThresholdSettings.CLUSTER_ROUTING_ALLOCATION_LOW_DISK_WATERMARK_SETTING.getKey(), (WATERMARK_BYTES * 2) + "b")
+ builder.put(DiskThresholdSettings.CLUSTER_ROUTING_ALLOCATION_LOW_DISK_WATERMARK_SETTING.getKey(), (WATERMARK_BYTES * 2) + "b")
.put(DiskThresholdSettings.CLUSTER_ROUTING_ALLOCATION_HIGH_DISK_WATERMARK_SETTING.getKey(), WATERMARK_BYTES + "b")
.put(DiskThresholdSettings.CLUSTER_ROUTING_ALLOCATION_DISK_FLOOD_STAGE_WATERMARK_SETTING.getKey(), "0b")
.put(DiskThresholdSettings.CLUSTER_ROUTING_ALLOCATION_REROUTE_INTERVAL_SETTING.getKey(), "0ms")
diff --git a/x-pack/plugin/autoscaling/src/main/java/org/elasticsearch/xpack/autoscaling/Autoscaling.java b/x-pack/plugin/autoscaling/src/main/java/org/elasticsearch/xpack/autoscaling/Autoscaling.java
index 07ffbe50c1445..482db005a07e4 100644
--- a/x-pack/plugin/autoscaling/src/main/java/org/elasticsearch/xpack/autoscaling/Autoscaling.java
+++ b/x-pack/plugin/autoscaling/src/main/java/org/elasticsearch/xpack/autoscaling/Autoscaling.java
@@ -7,7 +7,6 @@
package org.elasticsearch.xpack.autoscaling;
import org.apache.lucene.util.SetOnce;
-import org.elasticsearch.Build;
import org.elasticsearch.action.ActionRequest;
import org.elasticsearch.action.ActionResponse;
import org.elasticsearch.client.Client;
@@ -21,7 +20,6 @@
import org.elasticsearch.common.io.stream.NamedWriteableRegistry;
import org.elasticsearch.common.settings.ClusterSettings;
import org.elasticsearch.common.settings.IndexScopedSettings;
-import org.elasticsearch.common.settings.Setting;
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.common.settings.SettingsFilter;
import org.elasticsearch.common.xcontent.NamedXContentRegistry;
@@ -68,61 +66,21 @@
*/
public class Autoscaling extends Plugin implements ActionPlugin, ExtensiblePlugin, AutoscalingExtension {
- private static final Boolean AUTOSCALING_FEATURE_FLAG_REGISTERED;
-
static {
final String property = System.getProperty("es.autoscaling_feature_flag_registered");
- if (Build.CURRENT.isSnapshot() && property != null) {
- throw new IllegalArgumentException("es.autoscaling_feature_flag_registered is only supported in non-snapshot builds");
- }
- if ("true".equals(property)) {
- AUTOSCALING_FEATURE_FLAG_REGISTERED = true;
- } else if ("false".equals(property)) {
- AUTOSCALING_FEATURE_FLAG_REGISTERED = false;
- } else if (property == null) {
- AUTOSCALING_FEATURE_FLAG_REGISTERED = null;
- } else {
- throw new IllegalArgumentException(
- "expected es.autoscaling_feature_flag_registered to be unset or [true|false] but was [" + property + "]"
- );
+ if (property != null) {
+ throw new IllegalArgumentException("es.autoscaling_feature_flag_registered is no longer supported");
}
}
- public static final Setting AUTOSCALING_ENABLED_SETTING = Setting.boolSetting(
- "xpack.autoscaling.enabled",
- true,
- Setting.Property.NodeScope
- );
-
- private final boolean enabled;
-
private final List autoscalingExtensions;
private final SetOnce clusterService = new SetOnce<>();
private final SetOnce allocationDeciders = new SetOnce<>();
- public Autoscaling(final Settings settings) {
- this.enabled = AUTOSCALING_ENABLED_SETTING.get(settings);
+ public Autoscaling() {
this.autoscalingExtensions = new ArrayList<>(List.of(this));
}
- /**
- * The settings defined by autoscaling.
- *
- * @return the settings
- */
- @Override
- public List> getSettings() {
- if (isSnapshot() || (AUTOSCALING_FEATURE_FLAG_REGISTERED != null && AUTOSCALING_FEATURE_FLAG_REGISTERED)) {
- return List.of(AUTOSCALING_ENABLED_SETTING);
- } else {
- return List.of();
- }
- }
-
- boolean isSnapshot() {
- return Build.CURRENT.isSnapshot();
- }
-
@Override
public Collection