Skip to content

SNO 3027 kibana monitoring post refactor#294

Open
Bek wants to merge 2 commits intodevfrom
ENCD-3027-kibana-monitoring-post-refactor
Open

SNO 3027 kibana monitoring post refactor#294
Bek wants to merge 2 commits intodevfrom
ENCD-3027-kibana-monitoring-post-refactor

Conversation

@Bek
Copy link
Copy Markdown
Collaborator

@Bek Bek commented Oct 2, 2020

No description provided.

@Bek Bek requested review from hitz and keenangraham October 2, 2020 18:02
using=self._get_client(),
index=self._get_index(),
)
).extra(track_total_hits=True).query()
Copy link
Copy Markdown
Contributor

@keenangraham keenangraham Oct 2, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Think the ES7 upgrade stuff needs to be split into its own branch, but will make a note about this now.

This should be set in an independent step to keep the coupling between the base query object and the steps that build up that query object loose (we shouldn't force the children queries to always report exact hits in other words). You can follow same pattern of adding an .extra() parameter as is done for source here:

self.search = self._get_or_create_search().extra(

Then add that step (called something like self.add_total_hits()) to the query building instructions here:

Also I don't think we want to call .query() here unless the DSL has somehow changed. You can see it is called explicitly in other places e.g.:

self.search = self._get_or_create_search().query(

Copy link
Copy Markdown
Collaborator Author

@Bek Bek Oct 5, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will get the changes requested in this branch: https://github.com/ENCODE-DCC/snovault/tree/SNO-172-ES7-upgrade with just the upgrade related commit. The DSL has changed in a way that breaks the test assertions. Without calling the .query(), top level field, "query": {} part of the overall query object isn't returned. Let me know which you prefer changed, test assertions or the parent class here.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Empty Search no longer defaults to match_all query and instead leaves the query key empty. This is backwards incompatible when using suggest.

Kk. My guess is that we want to update the tests that expect this default to be returned, while making sure the tests that explicitly add a query still do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants