Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- Add support for enabling pluggable data formats, starting with phase-1 of decoupling shard from engine, and introducing basic abstractions ([#20675](https://github.com/opensearch-project/OpenSearch/pull/20675))

- Add warmup phase to wait for lag to catch up in pull-based ingestion before serving ([#20526](https://github.com/opensearch-project/OpenSearch/pull/20526))
- Add a new static method to IndicesOptions API to expose `STRICT_EXPAND_OPEN_HIDDEN_FORBID_CLOSED` index option ([#20980](https://github.com/opensearch-project/OpenSearch/pull/20980))

### Changed
- Make telemetry `Tags` immutable ([#20788](https://github.com/opensearch-project/OpenSearch/pull/20788))
- Move Randomness from server to libs/common ([#20570](https://github.com/opensearch-project/OpenSearch/pull/20570))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -589,6 +589,15 @@ public static IndicesOptions strictExpandOpenAndForbidClosed() {
return STRICT_EXPAND_OPEN_FORBID_CLOSED;
}

/**
* @return indices options that requires every specified index to exist, expand wildcards only to open indices,
* includes hidden indices, allows that no indices are resolved from wildcard expressions (not returning an error)
* and forbids the use of closed indices by throwing an error.
*/
public static IndicesOptions strictExpandOpenHiddenAndForbidClosed() {
return STRICT_EXPAND_OPEN_HIDDEN_FORBID_CLOSED;
}

/**
* @return indices options that requires every specified index to exist, expands wildcards only to open indices,
* allows that no indices are resolved from wildcard expressions (not returning an error),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1398,7 +1398,7 @@ protected final RefreshResponse refresh(String... indices) {
RefreshResponse actionGet = client().admin()
.indices()
.prepareRefresh(indices)
.setIndicesOptions(IndicesOptions.STRICT_EXPAND_OPEN_HIDDEN_FORBID_CLOSED)
.setIndicesOptions(IndicesOptions.strictExpandOpenHiddenAndForbidClosed())
.execute()
.actionGet();
assertNoFailures(actionGet);
Expand Down
Loading