remove lang url parameter from stored script requests (elastic/x-pack-elasticsearch#2029)
Original commit: elastic/x-pack-elasticsearch@1044c3ba53
This commit is contained in:
parent
5ecbbbd46d
commit
e007fee9fb
|
@ -230,7 +230,6 @@ public class BasicWatcherTests extends AbstractWatcherIntegrationTestCase {
|
|||
public void testConditionSearchWithIndexedTemplate() throws Exception {
|
||||
SearchSourceBuilder searchSourceBuilder = searchSource().query(matchQuery("level", "a"));
|
||||
assertAcked(client().admin().cluster().preparePutStoredScript()
|
||||
.setLang("mustache")
|
||||
.setId("my-template")
|
||||
.setContent(jsonBuilder().startObject().field("template").value(searchSourceBuilder).endObject().bytes(), XContentType.JSON)
|
||||
.get());
|
||||
|
|
|
@ -120,8 +120,8 @@ public class TransformIntegrationTests extends AbstractWatcherIntegrationTestCas
|
|||
logger.info("testing script transform with an indexed script");
|
||||
assertAcked(client().admin().cluster().preparePutStoredScript()
|
||||
.setId("my-script")
|
||||
.setLang("mockscript")
|
||||
.setContent(new BytesArray("{\"script\" : \"['key3' : ctx.payload.key1 + ctx.payload.key2]\"}"), XContentType.JSON)
|
||||
.setContent(new BytesArray("{\"script\" : {\"lang\": \"" + MockScriptPlugin.NAME + "\", " +
|
||||
"\"source\": \"['key3' : ctx.payload.key1 + ctx.payload.key2]\"}"), XContentType.JSON)
|
||||
.get());
|
||||
script = new Script(ScriptType.STORED, null, "my-script", Collections.emptyMap());
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue