CustomScoreQueryBuilder api working strangely

Hi.
I am using Custom Score query in my project.
It needs mainly 2 things: Query and Script.
For normal queries it works fine.
But if I put a nested query like bool query, then it puts script in
wrong position.
Is there a mistake in the api or am I not writing it correctly?

My code is at git://gist.github.com/1096535.git.
(The script is not at the query position.)

Can anybody please help me on this?

Regards.

Heya,

Its a bug in how the boosting query builder generates the query, fixed in
0.17 branch and master:
Java API: BoostingQueryBuilder does not build the query correctly · Issue #1141 · elastic/elasticsearch · GitHub.

-shay.banon

On Thu, Jul 21, 2011 at 8:27 AM, nachiket bhagwat <nachiketbhagwat@gmail.com

wrote:

Hi.
I am using Custom Score query in my project.
It needs mainly 2 things: Query and Script.
For normal queries it works fine.
But if I put a nested query like bool query, then it puts script in
wrong position.
Is there a mistake in the api or am I not writing it correctly?

My code is at git://gist.github.com/1096535.git.
(The script is not at the query position.)

Can anybody please help me on this?

Regards.

Hi.
I upgraded to 0.17.1 and then too the problem persisted.
My code is at Query Builders unable to build queries. · GitHub.
Can someone take a look at it?

Regards.

On Jul 21, 11:18 am, Shay Banon shay.ba...@elasticsearch.com wrote:

Heya,

Its a bug in how the boosting query builder generates the query, fixed in
0.17 branch and master:Java API: BoostingQueryBuilder does not build the query correctly · Issue #1141 · elastic/elasticsearch · GitHub.

-shay.banon

On Thu, Jul 21, 2011 at 8:27 AM, nachiket bhagwat <nachiketbhag...@gmail.com

wrote:
Hi.
I am using Custom Score query in my project.
It needs mainly 2 things: Query and Script.
For normal queries it works fine.
But if I put a nested query like bool query, then it puts script in
wrong position.
Is there a mistake in the api or am I not writing it correctly?

My code is at git://gist.github.com/1096535.git.
(The script is not at the query position.)

Can anybody please help me on this?

Regards.

It will be fixed in 0.17.2 (check the tags at:
Java API: BoostingQueryBuilder does not build the query correctly · Issue #1141 · elastic/elasticsearch · GitHub)

On Sat, Jul 23, 2011 at 4:33 PM, nachiket bhagwat <nachiketbhagwat@gmail.com

wrote:

Hi.
I upgraded to 0.17.1 and then too the problem persisted.
My code is at Query Builders unable to build queries. · GitHub.
Can someone take a look at it?

Regards.

On Jul 21, 11:18 am, Shay Banon shay.ba...@elasticsearch.com wrote:

Heya,

Its a bug in how the boosting query builder generates the query, fixed
in
0.17 branch and master:
Java API: BoostingQueryBuilder does not build the query correctly · Issue #1141 · elastic/elasticsearch · GitHub.

-shay.banon

On Thu, Jul 21, 2011 at 8:27 AM, nachiket bhagwat <
nachiketbhag...@gmail.com

wrote:
Hi.
I am using Custom Score query in my project.
It needs mainly 2 things: Query and Script.
For normal queries it works fine.
But if I put a nested query like bool query, then it puts script in
wrong position.
Is there a mistake in the api or am I not writing it correctly?

My code is at git://gist.github.com/1096535.git.
(The script is not at the query position.)

Can anybody please help me on this?

Regards.