-
Notifications
You must be signed in to change notification settings - Fork 24.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for field aliases. #32172
Commits on Jul 18, 2018
-
Add basic support for field aliases in index mappings. (#31287)
* Add basic support for field aliases through a new top-level mapper type. * Add tests for queries, aggregations, sorting, and fetching doc values. * Make sure we properly handle wildcard fields in query string queries. * Allow for aliases when requesting suggestions. * Allow for aliases when requesting highlights. * Add a test for field capabilities.
Configuration menu - View commit details
-
Copy full SHA for e2ebaed - Browse repository at this point
Copy the full SHA e2ebaedView commit details -
Allow for aliases when fetching stored fields. (#31411)
* When loading stored fields, resolve wildcard patterns against the mappings instead of the index. * Minor simplifications to the logic in FetchPhase. * Pull out a shared method FetchPhase#getSearchFields. * Allow for aliases when fetching stored fields.
Configuration menu - View commit details
-
Copy full SHA for f3de6f3 - Browse repository at this point
Copy the full SHA f3de6f3View commit details -
Add tests around accessing field aliases in scripts. (#31417)
* Make sure aliases can be referenced through params._fields. * Make sure aliases can be accessed through 'doc'. * Convert ExpressionTests to a unit test.
Configuration menu - View commit details
-
Copy full SHA for dddb76b - Browse repository at this point
Copy the full SHA dddb76bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 79fd45f - Browse repository at this point
Copy the full SHA 79fd45fView commit details -
Add validation for field alias mappings. (#31518)
* Perform basic validation on the target of an alias. * Validate that an alias and its target have the same nested scope. * Pull out some validation logic into a separate class. * Validate the uniqueness of field alias mappings.
Configuration menu - View commit details
-
Copy full SHA for 65ffdec - Browse repository at this point
Copy the full SHA 65ffdecView commit details -
Return both concrete fields and aliases in DocumentFieldMappers#getMa…
…pper. (#31671) * Rename DocumentFieldMappers#getMapper to getFieldMapper. * Introduce a new DocumentFieldMappers#getMapper that returns a Mapper. * Fix an issue around field aliases in geo suggestion contexts. * Make sure a field alias can refer to a percolate query. * Remove easy-to-fix uses of DocumentFieldMappers#getFieldMapper. * Include alias mappers in DocumentFieldMappers#getMappers. * Make sure we detect conflicts between dynamic object mappers and field aliases. * Throw an exception if aliases are specified as the target of copy_to.
Configuration menu - View commit details
-
Copy full SHA for ec65a79 - Browse repository at this point
Copy the full SHA ec65a79View commit details -
Make sure that field-level security is enforced when using field alia…
…ses. (#31807) * Add basic unit tests for field level security with field aliases. * Ensure that field caps information is filtered when a field alias is provided.
Configuration menu - View commit details
-
Copy full SHA for 5995794 - Browse repository at this point
Copy the full SHA 5995794View commit details -
Add more comprehensive tests for field aliases in queries + aggregati…
…ons. (#31565) * Make sure that significant terms aggregations work with field aliases. * Add a test for ValuesSourceConfig. * Allow for subclasses of AggregatorTestCase to provide field aliases. * Add tests for nested and reverse_nested aggregations. * Add an integration test for nested queries. * Add an integration test for 'more like this' queries. * Add tests for querying and loading meta-fields. * Add unit tests for the relevant query builders. * Add integration tests for geo polygon and shape queries. * Fix static analysis violations. * Document that aliases cannot be used in a query lookup path.
Configuration menu - View commit details
-
Copy full SHA for 6cfa032 - Browse repository at this point
Copy the full SHA 6cfa032View commit details -
Configuration menu - View commit details
-
Copy full SHA for c3ff6ce - Browse repository at this point
Copy the full SHA c3ff6ceView commit details