Hi, Mikhail! That is the real answer :). In other words: Lucene Searcher has 2 separate APIs: search and explain. They are independent with each other. At the same time, Elasticsearch provides the other approach where *explain *is not a "separate action", but is an additional setting to a *search *action. I'll probably ask that in Elasticsearch forum. Thanks :)
Regards Vadim Gindin On Tue, Jun 26, 2018 at 1:48 AM Mikhail Khludnev <m...@apache.org> wrote: > Vadim, > Why wouldn't you ask in Elastic forum? > > On Mon, Jun 25, 2018 at 11:39 PM Vadim Gindin <vgin...@detectum.com> > wrote: > > > Hi All. > > > > I've found that explain flag (that is set via URL) is transferred to > > DefaultSearchContext. I'd like to check this flag in my CustomQuery. I > > expected that SearchContext will be propagated to a Query, but I didn't > > found the way how to get. I only have LeafReaderContext or LeafReader. > > Could you advice me? > > > > Regards, > > Vadim Gindin > > > > > -- > Sincerely yours > Mikhail Khludnev >