Nested filter to nested query

Hello!

I have a question regarding the nested queries in 2.x version.
Before upgrade, I was using nested filters. But now, filters have converted into queries, and I am not allowed anymore to have something like: "nested" : { "filter": filter}.
Is it ok if I convert the filter into a bool query, something like;
{"nested": "query" : {"bool": {"filter"}}} ? Or should it be better if i put it in a constant_score query?
I am a little confused.

Thanks!

Hi @Cristiana_Tiugan,

you should be fine with a bool query and the filter parameter in your case (see also breaking query DSL changes in 2.0).

Daniel

Yes, I thought so, thanks a lot!

Cristiana