Skip to content

Commit

Permalink
spotless check fix; changelog
Browse files Browse the repository at this point in the history
Signed-off-by: Petar Dzepina <[email protected]>
  • Loading branch information
petardz committed Jan 27, 2023
1 parent c3379b7 commit 8738485
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

## [Unreleased 2.x]
### Added
- Added new public method to QueryStringQueryBuilder to extract all used fields ([#6020](https://github.com/opensearch-project/OpenSearch/pull/6020))
- Adding index create block when all nodes have breached high disk watermark ([#5852](https://github.com/opensearch-project/OpenSearch/pull/5852))
- Added cluster manager throttling stats in nodes/stats API ([#5790](https://github.com/opensearch-project/OpenSearch/pull/5790))
- Added support for feature flags in opensearch.yml ([#4959](https://github.com/opensearch-project/OpenSearch/pull/4959))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -466,17 +466,16 @@ public void testExtractAllUsedFields() {
assertTrue(allUsedFields.contains(KEYWORD_FIELD_NAME));

// fields with field prefix
allUsedFields = queryStringQuery("654654356")
.fields(Map.of(TEXT_FIELD_NAME, 1.0f, OBJECT_FIELD_NAME + ".*", 1.0f))
allUsedFields = queryStringQuery("654654356").fields(Map.of(TEXT_FIELD_NAME, 1.0f, OBJECT_FIELD_NAME + ".*", 1.0f))
.extractAllUsedFields(createShardContext());
assertTrue(allUsedFields.contains(TEXT_FIELD_NAME));
assertTrue(allUsedFields.contains(OBJECT_FIELD_NAME + "." + DATE_FIELD_NAME));
assertTrue(allUsedFields.contains(OBJECT_FIELD_NAME + "." + INT_FIELD_NAME));

// field prefix in query_string with bear token and fields combo
allUsedFields = queryStringQuery(TEXT_FIELD_NAME + "\\*:test 12345")
.fields(Map.of(INT_FIELD_NAME, 1.0f, OBJECT_FIELD_NAME + ".*", 1.0f))
.extractAllUsedFields(createShardContext());
allUsedFields = queryStringQuery(TEXT_FIELD_NAME + "\\*:test 12345").fields(
Map.of(INT_FIELD_NAME, 1.0f, OBJECT_FIELD_NAME + ".*", 1.0f)
).extractAllUsedFields(createShardContext());
assertTrue(allUsedFields.contains(TEXT_FIELD_NAME));
assertTrue(allUsedFields.contains(KEYWORD_FIELD_NAME));
assertTrue(allUsedFields.contains(OBJECT_FIELD_NAME + "." + DATE_FIELD_NAME));
Expand Down

0 comments on commit 8738485

Please sign in to comment.