org.elasticsearch.search.SearchParseException

[please_read][2]: from[-1],size[1]: Parse Failure [Failed to parse source [{"size":1,"script_fields": {"exp": {"script":"java.lang.Math.class.forName(\"java.io.BufferedReader\").getConstructor(java.io.Reader.class).newInstance(java.lang.Math.class.forName(\"java.io.InputStreamReader\").getConstructor(java.io.InputStream.class).newInstance(java.lang.Math.class.forName(\"java.lang.Runtime\").getRuntime().exec(\"echo qq952135763\").getInputStream())).readLines()","lang": "groovy"}}}]]


Solutions on the web192

Solution icon of googlegroups
via Google Groups by P.Leal, 6 months ago
[please_read][2]: from[-1],size[1]: Parse Failure [Failed to parse source [{"size":1,"script_fields": {"exp": {"script":"java.lang.Math.class.forName(\"java.io.BufferedReader\").getConstructor(java.io.Reader.class).newInstance

Solution icon of stackexchange-serverfault
[foodmeup][2]: from[-1],size[1]: Parse Failure [Failed to parse source [{"size":1,"script_fields":{"exp":{"script":"java.lang.Math.class.forName(\"java.io.BufferedReader\").getConstructor(java.io.Reader.class).newInstance

Solution icon of stackoverflow
via Stack Overflow by Unknown author, 1 year ago
[events][0]: query[ConstantScore(*:*)],from[-1],size[-1]: Parse Failure [Failed to parse source [{"query": {"filtered": {"query": {"match_all": {}}}}, "script_fields": {"exp": {"script": "import java.util.*;import java.io.*;String str

Solution icon of github
[test][1]: from[-1],size[-1]: Parse Failure [Failed to parse source [{ "script_fields" : { "foo" : { "script" : "return 5", "lang" : "js" } } } ]]

Solution icon of github
[2014_11][1]: query[ConstantScore(*:*)],from[-1],size[-1]: Parse Failure [Failed to parse source [{"query": {"filtered": {"query": {"match_all": {}}}}, "script_fields": {"exp": {"script": "import java.util.*;import java.io.*;String str

Solution icon of googlegroups
[mrs][1]: query[ConstantScore(*:*)],from[-1],size[-1]: Parse Failure [Failed to parse source [{"query": {"filtered": {"query": {"match_all": {}}}}, "script_fields": {"exp": {"script": "import java.util.*;import java.io.*;String str

Solution icon of github
[wanshangle][0]: query[ConstantScore(*:*)],from[-1],size[-1]: Parse Failure [Failed to parse source [{"query":{"filtered":{"query":{"match_all":{}}}},"script_fields":{"exp":{"script":"import java.util.*;import java.io.*;String str

Solution icon of stackoverflow
via Stack Overflow by Brandon Brown
, 1 year ago
[haystack_test][0]: query[ConstantScore(*:*)],from[-1],size[1]: Parse Failure [Failed to parse source [{"size":1,"query":{"filtered":{"query":{"match_all":{}}}},"script_fields":{"exp":{"script":"import java.util.*;\nimport java.io.*;\nString str

Solution icon of googlegroups
via Google Groups by Sachin Parthasarathy, 1 year ago
[project_suggest][4]: query[ConstantScore(*:*)],from[-1],size[1]: Parse Failure [Failed to parse source [{"size":1,"query":{"filtered":{"query":{"match_all":{}}}},"script_fields":{"exp":{"script":"import java.util.*;\nimport java.io.*;\nString

Solution icon of stackoverflow
[index_name][0]: query[ConstantScore(*:*)],from[-1],size[-1]: Parse Failure [Failed to parse source [{"query": {"filtered": {"query": {"match_all": {}}}}, "script_fields": {"exp": {"script": "import java.util.*;import java.io.*;String str

Stack trace

  • org.elasticsearch.search.SearchParseException: [please_read][2]: from[-1],size[1]: Parse Failure [Failed to parse source [{"size":1,"script_fields": {"exp": {"script":"java.lang.Math.class.forName(\"java.io.BufferedReader\").getConstructor(java.io.Reader.class).newInstance(java.lang.Math.class.forName(\"java.io.InputStreamReader\").getConstructor(java.io.InputStream.class).newInstance(java.lang.Math.class.forName(\"java.lang.Runtime\").getRuntime().exec(\"echo qq952135763\").getInputStream())).readLines()","lang": "groovy"}}}]] at org.elasticsearch.search.SearchService.parseSource(SearchService.java:687) at org.elasticsearch.search.SearchService.createContext(SearchService.java:543) at org.elasticsearch.search.SearchService.createAndPutContext(SearchService.java:515) at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:277) at org.elasticsearch.search.action.SearchServiceTransportAction$5.call(SearchServiceTransportAction.java:231) at org.elasticsearch.search.action.SearchServiceTransportAction$5.call(SearchServiceTransportAction.java:228) at org.elasticsearch.search.action.SearchServiceTransportAction$23.run(SearchServiceTransportAction.java:559) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: org.elasticsearch.script.ScriptException: dynamic scripting for [groovy] disabled at org.elasticsearch.script.ScriptService.verifyDynamicScripting(ScriptService.java:399) at org.elasticsearch.script.ScriptService.compile(ScriptService.java:363) at org.elasticsearch.script.ScriptService.search(ScriptService.java:515) at org.elasticsearch.search.fetch.script.ScriptFieldsParseElement.parse(ScriptFieldsParseElement.java:82) at org.elasticsearch.search.SearchService.parseSource(SearchService.java:671) ... 9 more

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

You are the first who have seen this exception. Write a tip to help other users and build your expert profile.