Skip to content

Conversation

@markharwood
Copy link
Contributor

New metadata field, like the "_index" field that supports term, terms and wildcard queries on the roles defined (explicitly or implicitly)for a node.

Will add tests if we think this is the way forward

Closes #68135

@markharwood markharwood self-assigned this Feb 19, 2021
@markharwood markharwood added :Search Foundations/Mapping Index mappings, including merging and defining field types >new-field-mapper Added when a new field type / mapper is being introduced labels Feb 19, 2021
@elasticmachine elasticmachine added the Team:Search Meta label for search team label Feb 19, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search (Team:Search)

@markharwood markharwood force-pushed the fix/68135 branch 2 times, most recently from 2a6fedc to e86181e Compare February 22, 2021 13:41
@markharwood markharwood force-pushed the fix/68135 branch 2 times, most recently from b5570c7 to d5c838d Compare February 23, 2021 14:44
@markharwood
Copy link
Contributor Author

@jpountz I commented out the familyTypeName support for now - was breaking some SQL test expectations

@henningandersen
Copy link
Contributor

I wonder if the approach taken here allows for sorting by "_tier" too? If so, it would be sort of nice to let the order be "content", "hot", "warm", "cold", "frozen", regardless of alphabetical ordering. Not sure I have a killer case for this though.

@markharwood
Copy link
Contributor Author

This PR has two dependencies:

  1. sorting/aggregations - can't sort or aggregate until ConstantFieldType.fielddataBuilder() is changed to pass a SearchExecutionContext object (or a new interface that also spans AggregationExecutionContext)
  2. some work Jim is doing on stripping metadata fields like _tier from the field caps API (we suspect this is behind the SQL test failures currently on this PR).

With regards to 1) I suspect we can merge this PR minus sort/aggs support and save for another issue.

Copy link
Contributor

@jimczi jimczi left a comment

Choose a reason for hiding this comment

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

I left some comments but the logic looks good to me.

Copy link
Contributor

@jimczi jimczi left a comment

Choose a reason for hiding this comment

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

I left minor comments, LGTM otherwise.

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

Labels

>enhancement >new-field-mapper Added when a new field type / mapper is being introduced :Search Foundations/Mapping Index mappings, including merging and defining field types Team:Search Meta label for search team v7.13.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add ability to filter query based on data tier

7 participants