Migrating QueryBuilders API to lightweight Java REST Client that come with 5.0


(Rajind Ruparathna) #1

Hi,
I've read that a query builder API for lightweight Java REST Client might not be released with 5.0 GA. So I would like to know whether it will be possible to plug-in "org.elasticsearch.index.query.QueryBuilders" API to the lightweight Java REST client ? I am willing to spend some time and effort on it but first I would like to have some idea if it is possible.

Cheers!


(David Pilato) #2

The problem for now is that QueryBuilders are part of elasticsearch core so if you depend on this JAR, you will have tons of dependencies coming with it. I'm unsure if you can remove some of them but it will be a hard manual work I believe.

We have a plan of providing query builders but there is no date written in stone for that.

If you use query builders and are successful with that, I'll be happy to hear about what you did.

You can probably use toXContent() method to build a JSON String out of the QB.


(system) #3