Remove deprecated script settings. (elastic/x-pack-elasticsearch#1469)
Original commit: elastic/x-pack-elasticsearch@069e5a1087
This commit is contained in:
parent
667f842f92
commit
b92a2f6582
|
@ -111,7 +111,7 @@ def smoke_test_release(release, files, release_hash):
|
||||||
|
|
||||||
print(' Starting elasticsearch daemon from [%s]' % es_dir)
|
print(' Starting elasticsearch daemon from [%s]' % es_dir)
|
||||||
try:
|
try:
|
||||||
run('%s; %s -Enode.name=smoke_tester -Ecluster.name=prepare_release -Escript.inline=true -Escript.stored=true -Erepositories.url.allowed_urls=http://snapshot.test* %s -Epidfile=%s -Enode.portsfile=true'
|
run('%s; %s -Enode.name=smoke_tester -Ecluster.name=prepare_release -Erepositories.url.allowed_urls=http://snapshot.test* %s -Epidfile=%s -Enode.portsfile=true'
|
||||||
% (java_exe(), es_run_path, '-d', os.path.join(es_dir, 'es-smoke.pid')))
|
% (java_exe(), es_run_path, '-d', os.path.join(es_dir, 'es-smoke.pid')))
|
||||||
if not wait_for_node_startup(es_dir, headers=headers):
|
if not wait_for_node_startup(es_dir, headers=headers):
|
||||||
print("elasticsearch logs:")
|
print("elasticsearch logs:")
|
||||||
|
|
|
@ -144,7 +144,6 @@ Closure waitWithAuth = { NodeInfo node, AntBuilder ant ->
|
||||||
|
|
||||||
integTestCluster {
|
integTestCluster {
|
||||||
plugin ':x-pack-elasticsearch:plugin'
|
plugin ':x-pack-elasticsearch:plugin'
|
||||||
setting 'script.inline', 'true'
|
|
||||||
setupCommand 'setupTestAdmin',
|
setupCommand 'setupTestAdmin',
|
||||||
'bin/x-pack/users', 'useradd', 'test_admin', '-p', 'changeme', '-r', 'superuser'
|
'bin/x-pack/users', 'useradd', 'test_admin', '-p', 'changeme', '-r', 'superuser'
|
||||||
waitCondition = waitWithAuth
|
waitCondition = waitWithAuth
|
||||||
|
|
|
@ -29,7 +29,6 @@ public class MonitoringF {
|
||||||
|
|
||||||
public static void main(String[] args) throws Throwable {
|
public static void main(String[] args) throws Throwable {
|
||||||
Settings.Builder settings = Settings.builder();
|
Settings.Builder settings = Settings.builder();
|
||||||
settings.put("script.inline", "true");
|
|
||||||
settings.put("security.manager.enabled", "false");
|
settings.put("security.manager.enabled", "false");
|
||||||
settings.put("cluster.name", MonitoringF.class.getSimpleName());
|
settings.put("cluster.name", MonitoringF.class.getSimpleName());
|
||||||
settings.put("xpack.monitoring.collection.interval", "1s");
|
settings.put("xpack.monitoring.collection.interval", "1s");
|
||||||
|
|
|
@ -38,7 +38,6 @@ public class SecurityF {
|
||||||
Settings.Builder settings = Settings.builder();
|
Settings.Builder settings = Settings.builder();
|
||||||
settings.put("http.cors.enabled", "true");
|
settings.put("http.cors.enabled", "true");
|
||||||
settings.put("http.cors.allow-origin", "*");
|
settings.put("http.cors.allow-origin", "*");
|
||||||
settings.put("script.inline", "true");
|
|
||||||
settings.put("xpack.security.enabled", "true");
|
settings.put("xpack.security.enabled", "true");
|
||||||
// Disable Monitoring to prevent cluster activity
|
// Disable Monitoring to prevent cluster activity
|
||||||
settings.put("xpack.monitoring.enabled", "false");
|
settings.put("xpack.monitoring.enabled", "false");
|
||||||
|
|
|
@ -31,7 +31,6 @@ public class WatcherF {
|
||||||
Settings.Builder settings = Settings.builder();
|
Settings.Builder settings = Settings.builder();
|
||||||
settings.put("http.cors.enabled", "true");
|
settings.put("http.cors.enabled", "true");
|
||||||
settings.put("http.cors.allow-origin", "*");
|
settings.put("http.cors.allow-origin", "*");
|
||||||
settings.put("script.inline", "true");
|
|
||||||
settings.put("xpack.security.enabled", "false");
|
settings.put("xpack.security.enabled", "false");
|
||||||
settings.put("security.manager.enabled", "false");
|
settings.put("security.manager.enabled", "false");
|
||||||
settings.put("cluster.name", WatcherF.class.getSimpleName());
|
settings.put("cluster.name", WatcherF.class.getSimpleName());
|
||||||
|
|
|
@ -29,7 +29,6 @@ import org.elasticsearch.script.ScriptEngineRegistry;
|
||||||
import org.elasticsearch.script.ScriptException;
|
import org.elasticsearch.script.ScriptException;
|
||||||
import org.elasticsearch.script.ScriptMetaData;
|
import org.elasticsearch.script.ScriptMetaData;
|
||||||
import org.elasticsearch.script.ScriptService;
|
import org.elasticsearch.script.ScriptService;
|
||||||
import org.elasticsearch.script.ScriptSettings;
|
|
||||||
import org.elasticsearch.script.ScriptType;
|
import org.elasticsearch.script.ScriptType;
|
||||||
import org.elasticsearch.search.internal.InternalSearchResponse;
|
import org.elasticsearch.search.internal.InternalSearchResponse;
|
||||||
import org.elasticsearch.test.ESTestCase;
|
import org.elasticsearch.test.ESTestCase;
|
||||||
|
@ -90,10 +89,8 @@ public class ScriptConditionTests extends ESTestCase {
|
||||||
|
|
||||||
ScriptEngineRegistry registry = new ScriptEngineRegistry(singleton(engine));
|
ScriptEngineRegistry registry = new ScriptEngineRegistry(singleton(engine));
|
||||||
ScriptContextRegistry contextRegistry = new ScriptContextRegistry(singleton(new ScriptContext.Plugin("xpack", "watch")));
|
ScriptContextRegistry contextRegistry = new ScriptContextRegistry(singleton(new ScriptContext.Plugin("xpack", "watch")));
|
||||||
ScriptSettings scriptSettings = new ScriptSettings(registry, contextRegistry);
|
scriptService = new ScriptService(Settings.EMPTY, registry, contextRegistry);
|
||||||
|
|
||||||
|
|
||||||
scriptService = new ScriptService(Settings.EMPTY, registry, contextRegistry, scriptSettings);
|
|
||||||
ClusterState.Builder clusterState = new ClusterState.Builder(new ClusterName("_name"));
|
ClusterState.Builder clusterState = new ClusterState.Builder(new ClusterName("_name"));
|
||||||
clusterState.metaData(MetaData.builder().putCustom(ScriptMetaData.TYPE, new ScriptMetaData.Builder(null).build()));
|
clusterState.metaData(MetaData.builder().putCustom(ScriptMetaData.TYPE, new ScriptMetaData.Builder(null).build()));
|
||||||
ClusterState cs = clusterState.build();
|
ClusterState cs = clusterState.build();
|
||||||
|
|
|
@ -146,7 +146,6 @@ public abstract class AbstractWatcherIntegrationTestCase extends ESIntegTestCase
|
||||||
.put("xpack.watcher.execution.scroll.size", randomIntBetween(1, 100))
|
.put("xpack.watcher.execution.scroll.size", randomIntBetween(1, 100))
|
||||||
.put("xpack.watcher.watch.scroll.size", randomIntBetween(1, 100))
|
.put("xpack.watcher.watch.scroll.size", randomIntBetween(1, 100))
|
||||||
.put(SecuritySettings.settings(securityEnabled))
|
.put(SecuritySettings.settings(securityEnabled))
|
||||||
.put("script.inline", "true")
|
|
||||||
// Disable native ML autodetect_process as the c++ controller won't be available
|
// Disable native ML autodetect_process as the c++ controller won't be available
|
||||||
.put(MachineLearning.AUTODETECT_PROCESS.getKey(), false)
|
.put(MachineLearning.AUTODETECT_PROCESS.getKey(), false)
|
||||||
.build();
|
.build();
|
||||||
|
|
|
@ -21,7 +21,6 @@ import org.elasticsearch.script.ScriptContext;
|
||||||
import org.elasticsearch.script.ScriptContextRegistry;
|
import org.elasticsearch.script.ScriptContextRegistry;
|
||||||
import org.elasticsearch.script.ScriptEngineRegistry;
|
import org.elasticsearch.script.ScriptEngineRegistry;
|
||||||
import org.elasticsearch.script.ScriptService;
|
import org.elasticsearch.script.ScriptService;
|
||||||
import org.elasticsearch.script.ScriptSettings;
|
|
||||||
import org.elasticsearch.search.builder.SearchSourceBuilder;
|
import org.elasticsearch.search.builder.SearchSourceBuilder;
|
||||||
import org.elasticsearch.test.ESIntegTestCase;
|
import org.elasticsearch.test.ESIntegTestCase;
|
||||||
import org.elasticsearch.threadpool.ThreadPool;
|
import org.elasticsearch.threadpool.ThreadPool;
|
||||||
|
@ -238,8 +237,6 @@ public final class WatcherTestUtils {
|
||||||
|
|
||||||
public static ScriptService createScriptService(ThreadPool tp) throws Exception {
|
public static ScriptService createScriptService(ThreadPool tp) throws Exception {
|
||||||
Settings settings = Settings.builder()
|
Settings settings = Settings.builder()
|
||||||
.put("script.inline", "true")
|
|
||||||
.put("script.indexed", "true")
|
|
||||||
.put("path.home", createTempDir())
|
.put("path.home", createTempDir())
|
||||||
.build();
|
.build();
|
||||||
ScriptContextRegistry scriptContextRegistry =
|
ScriptContextRegistry scriptContextRegistry =
|
||||||
|
@ -247,8 +244,8 @@ public final class WatcherTestUtils {
|
||||||
|
|
||||||
ScriptEngineRegistry scriptEngineRegistry =
|
ScriptEngineRegistry scriptEngineRegistry =
|
||||||
new ScriptEngineRegistry(Collections.emptyList());
|
new ScriptEngineRegistry(Collections.emptyList());
|
||||||
ScriptSettings scriptSettings = new ScriptSettings(scriptEngineRegistry, scriptContextRegistry);
|
|
||||||
return new ScriptService(settings, scriptEngineRegistry, scriptContextRegistry, scriptSettings);
|
return new ScriptService(settings, scriptEngineRegistry, scriptContextRegistry);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static SearchType getRandomSupportedSearchType() {
|
public static SearchType getRandomSupportedSearchType() {
|
||||||
|
|
|
@ -99,8 +99,6 @@ public class TransformIntegrationTests extends AbstractWatcherIntegrationTestCas
|
||||||
return Settings.builder()
|
return Settings.builder()
|
||||||
.put(baseSettings)
|
.put(baseSettings)
|
||||||
.put(Environment.PATH_CONF_SETTING.getKey(), config)
|
.put(Environment.PATH_CONF_SETTING.getKey(), config)
|
||||||
.put("script.stored", "true")
|
|
||||||
.put("script.inline", "true")
|
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -7,6 +7,5 @@ dependencies {
|
||||||
|
|
||||||
integTestCluster {
|
integTestCluster {
|
||||||
setting 'xpack.security.enabled', 'false'
|
setting 'xpack.security.enabled', 'false'
|
||||||
setting 'script.inline', 'true'
|
|
||||||
plugin ':x-pack-elasticsearch:plugin'
|
plugin ':x-pack-elasticsearch:plugin'
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,7 +8,6 @@ dependencies {
|
||||||
}
|
}
|
||||||
|
|
||||||
integTestCluster {
|
integTestCluster {
|
||||||
setting 'script.inline', 'true'
|
|
||||||
plugin ':x-pack-elasticsearch:plugin'
|
plugin ':x-pack-elasticsearch:plugin'
|
||||||
// Whitelist reindexing from the local node so we can test it.
|
// Whitelist reindexing from the local node so we can test it.
|
||||||
setting 'reindex.remote.whitelist', '127.0.0.1:*'
|
setting 'reindex.remote.whitelist', '127.0.0.1:*'
|
||||||
|
|
|
@ -7,7 +7,6 @@ dependencies {
|
||||||
}
|
}
|
||||||
|
|
||||||
integTestCluster {
|
integTestCluster {
|
||||||
setting 'script.inline', 'true'
|
|
||||||
plugin ':x-pack-elasticsearch:plugin'
|
plugin ':x-pack-elasticsearch:plugin'
|
||||||
extraConfigFile 'x-pack/roles.yml', 'roles.yml'
|
extraConfigFile 'x-pack/roles.yml', 'roles.yml'
|
||||||
[
|
[
|
||||||
|
|
|
@ -10,8 +10,6 @@ integTestCluster {
|
||||||
plugin ':x-pack-elasticsearch:plugin'
|
plugin ':x-pack-elasticsearch:plugin'
|
||||||
setting 'xpack.security.enabled', 'false'
|
setting 'xpack.security.enabled', 'false'
|
||||||
setting 'xpack.monitoring.enabled', 'false'
|
setting 'xpack.monitoring.enabled', 'false'
|
||||||
setting 'script.inline', 'true'
|
|
||||||
setting 'script.stored', 'true'
|
|
||||||
// Need to allow more compilations per minute because of the integration tests
|
// Need to allow more compilations per minute because of the integration tests
|
||||||
setting 'script.max_compilations_per_minute', '100'
|
setting 'script.max_compilations_per_minute', '100'
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,7 +15,6 @@ import org.elasticsearch.script.ScriptContext;
|
||||||
import org.elasticsearch.script.ScriptContextRegistry;
|
import org.elasticsearch.script.ScriptContextRegistry;
|
||||||
import org.elasticsearch.script.ScriptEngineRegistry;
|
import org.elasticsearch.script.ScriptEngineRegistry;
|
||||||
import org.elasticsearch.script.ScriptService;
|
import org.elasticsearch.script.ScriptService;
|
||||||
import org.elasticsearch.script.ScriptSettings;
|
|
||||||
import org.elasticsearch.script.mustache.MustacheScriptEngine;
|
import org.elasticsearch.script.mustache.MustacheScriptEngine;
|
||||||
import org.elasticsearch.test.ESTestCase;
|
import org.elasticsearch.test.ESTestCase;
|
||||||
import org.elasticsearch.watcher.ResourceWatcherService;
|
import org.elasticsearch.watcher.ResourceWatcherService;
|
||||||
|
@ -46,8 +45,7 @@ public class WatcherTemplateIT extends ESTestCase {
|
||||||
ScriptEngineRegistry scriptEngineRegistry = new ScriptEngineRegistry(
|
ScriptEngineRegistry scriptEngineRegistry = new ScriptEngineRegistry(
|
||||||
Collections.singleton(new MustacheScriptEngine())
|
Collections.singleton(new MustacheScriptEngine())
|
||||||
);
|
);
|
||||||
ScriptSettings scriptSettings = new ScriptSettings(scriptEngineRegistry, registry);
|
ScriptService scriptService = new ScriptService(Settings.EMPTY, scriptEngineRegistry, registry);
|
||||||
ScriptService scriptService = new ScriptService(Settings.EMPTY, scriptEngineRegistry, registry, scriptSettings);
|
|
||||||
engine = new TextTemplateEngine(Settings.EMPTY, scriptService);
|
engine = new TextTemplateEngine(Settings.EMPTY, scriptService);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,6 @@ dependencies {
|
||||||
|
|
||||||
integTestCluster {
|
integTestCluster {
|
||||||
plugin ':x-pack-elasticsearch:plugin'
|
plugin ':x-pack-elasticsearch:plugin'
|
||||||
setting 'script.inline', 'true'
|
|
||||||
setting 'xpack.security.enabled', 'false'
|
setting 'xpack.security.enabled', 'false'
|
||||||
setting 'xpack.monitoring.enabled', 'false'
|
setting 'xpack.monitoring.enabled', 'false'
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,6 +8,5 @@ dependencies {
|
||||||
|
|
||||||
integTestCluster {
|
integTestCluster {
|
||||||
setting 'xpack.security.enabled', 'false'
|
setting 'xpack.security.enabled', 'false'
|
||||||
setting 'script.inline', 'true'
|
|
||||||
plugin ':x-pack-elasticsearch:plugin'
|
plugin ':x-pack-elasticsearch:plugin'
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue