Skip to content

Commit

Permalink
Flat object field should delegate to keyword field for most query types
Browse files Browse the repository at this point in the history
Signed-off-by: kkewwei <[email protected]>
  • Loading branch information
kkewwei committed Sep 19, 2024
1 parent 3a1b6d1 commit 88ca24f
Show file tree
Hide file tree
Showing 8 changed files with 1,990 additions and 259 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- [Workload Management] QueryGroup resource cancellation framework changes ([#15651](https://github.com/opensearch-project/OpenSearch/pull/15651))
- Fallback to Remote cluster-state on Term-Version check mismatch - ([#15424](https://github.com/opensearch-project/OpenSearch/pull/15424))
- Implement WithFieldName interface in ValuesSourceAggregationBuilder & FieldSortBuilder ([#15916](https://github.com/opensearch-project/OpenSearch/pull/15916))
- Flat object field use IndexOrDocValuesQuery to optimize query ([#14383](https://github.com/opensearch-project/OpenSearch/issues/14383))

### Dependencies
- Bump `com.azure:azure-identity` from 1.13.0 to 1.13.2 ([#15578](https://github.com/opensearch-project/OpenSearch/pull/15578))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -627,38 +627,6 @@ teardown:
- match: { error.root_cause.0.reason: "Mapping definition for [data] has unsupported parameters: [analyzer : standard]"}
- match: { status: 400 }

# Wildcard Query with dot path.
- do:
catch: bad_request
search:
body: {
_source: true,
query: {
"wildcard": {
"catalog.title": "Mock*"
}
}
}
- match: { error.root_cause.0.type: "query_shard_exception" }
- match: { error.root_cause.0.reason: "Can only use wildcard queries on keyword and text fields - not on [catalog.title] which is of type [flat_object]"}
- match: { status: 400 }

# Wildcard Query without dot path.
- do:
catch: bad_request
search:
body: {
_source: true,
query: {
"wildcard": {
"catalog": "Mock*"
}
}
}
- match: { error.root_cause.0.type: "query_shard_exception" }
- match: { error.root_cause.0.reason: "Can only use wildcard queries on keyword and text fields - not on [catalog] which is of type [flat_object]" }
- match: { status: 400 }

# Aggregation and Match Query with dot path.
- do:
catch: bad_request
Expand Down
Loading

0 comments on commit 88ca24f

Please sign in to comment.