I am trying to execute a URI based query like below. But i don't see any effect of the search parameters i am passing. And also i want to disable _source=false. Can you help me with the query. I am using java to perform the same using Java.net packages. This query return everything no matter what search parameter i pass.
URI: "http://localhost:9200/twitter/twitter/_search?updatedBy=XX&node=YY"
Java Code:
String charset = "UTF-8";
String updatedBy = "XX";
String node = "YY";
String query = String.format("updatedBy:%s&nodeId:%s",
URLEncoder.encode(updatedBy, charset),
URLEncoder.encode(nodeId, charset));
System.out.println(searchEsUrl + "?q=" + query);
URLConnection connection = new URL(searchEsUrl + "?q=" + query).openConnection();
connection.setRequestProperty("Accept-Charset", charset);