Fix compilation for ScriptMode removal
See: https://github.com/elastic/elasticsearch/pull/18502 Original commit: elastic/x-pack-elasticsearch@b0422d13df
This commit is contained in:
parent
c2ae64c7ed
commit
5d93b51472
|
@ -5,7 +5,6 @@
|
|||
*/
|
||||
package org.elasticsearch.script;
|
||||
|
||||
import org.elasticsearch.script.ScriptMode;
|
||||
import org.elasticsearch.xpack.common.text.DefaultTextTemplateEngine;
|
||||
|
||||
import java.util.Collections;
|
||||
|
@ -29,8 +28,7 @@ public class MockMustacheScriptEngine extends MockScriptEngine {
|
|||
}
|
||||
|
||||
public void onModule(ScriptModule module) {
|
||||
module.addScriptEngine(new ScriptEngineRegistry.ScriptEngineRegistration(MockMustacheScriptEngine.class,
|
||||
NAME, ScriptMode.ON));
|
||||
module.addScriptEngine(new ScriptEngineRegistry.ScriptEngineRegistration(MockMustacheScriptEngine.class, NAME, true));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -7,7 +7,6 @@ package org.elasticsearch.script;
|
|||
|
||||
import org.elasticsearch.common.Nullable;
|
||||
import org.elasticsearch.plugins.Plugin;
|
||||
import org.elasticsearch.script.ScriptMode;
|
||||
import org.elasticsearch.search.lookup.SearchLookup;
|
||||
|
||||
import java.io.IOException;
|
||||
|
@ -39,7 +38,7 @@ public class SleepScriptEngine implements ScriptEngineService {
|
|||
|
||||
public void onModule(ScriptModule module) {
|
||||
module.addScriptEngine(new ScriptEngineRegistry.ScriptEngineRegistration(SleepScriptEngine.class,
|
||||
SleepScriptEngine.NAME, ScriptMode.ON));
|
||||
SleepScriptEngine.NAME, true));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue