Commit Graph

6053 Commits

Author SHA1 Message Date
Nick Knize 3b71ea6c1e
[Javadocs] add to o.o.search.rescore,searchafter,slice, sort, and suggest (#3264)
Adds class level javadocs to org.opensearch.search, and
org.opensearch.search.rescore, searchAfter, slice, sort, and suggest
subpackages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-09 16:20:56 -07:00
Nick Knize 1118dcf372
[Javadocs] add to o.o.dfs,fetch,internal,lookup,profile, and query packages (#3261)
Adds class level javadocs to org.opensearch.dfs, fetch, internal, lookup,
profile, and query packages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-09 14:05:59 -05:00
Nick Knize 625623f932
[Javadocs] add to o.o.search.aggs, builder, and collapse packages (#3254)
Adds class level javadocs to org.opensearch.search.aggregations, builder, and
collapse packages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-09 11:20:19 -07:00
Nick Knize 15161a8649
[Javadocs] add to o.o.rest, snapshots, and tasks packages (#3219)
Adds javadocs to org.opensearch.rest, snapshots, and tasks packages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-06 11:03:01 -07:00
Nick Knize a7715ab6ce
[Javadocs] add to o.o.transport (#3220)
Adds javadocs to the org.opensearch.transport package.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-06 08:36:04 -05:00
Nick Knize 7b75fb425f
[Javadocs] add to o.o.index and indices (#3209)
Adds javadocs to org.opensearch.index and indices packages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-05 17:06:48 -05:00
opensearch-trigger-bot[bot] c41b41140b
Added bwc version 1.3.3 (#3205)
Signed-off-by: GitHub <noreply@github.com>

Co-authored-by: opensearch-ci-bot <opensearch-ci-bot@users.noreply.github.com>
2022-05-05 16:19:04 -04:00
Kartik Ganesh 44573baff2
Moving RecoveryState.Index to a top-level class and renaming (#3075)
* Moving RecoveryState.Index to a top-level class and renaming

This class is a building block of replication and will be re-used between peer recovery and segment replication. Thus, the inner class has been extracted to a top-level class and moved to the replication.common package. It has been renamed to ReplicationLuceneIndex to better reflect what it represents. It has two dependent inner classes from RecoveryState that have also been moved along with it - these remain inner classes since they are not currently used anywhere else. The RecoveryFilesDetails class has been renamed to FilesDetails and the FileDetail class has been renamed to FileMetadata.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Incorporate PR comments

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Revert Project_Default.xml

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Update REST Action test to no longer mock a final class

Instead, the test now populates dummy data.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Removing mocking of ReplicationLuceneIndex in RecoverySourceHandlerTests

The class has been marked final, so it can no longer be mocked. Instead, the test class sets up the lucene index class by adding the smae file metadata that is set up for the store.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Configure @opensearch.internal as custom Javadoc tag

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Revert "Configure @opensearch.internal as custom Javadoc tag"

This reverts commit 2077d76e421fc2ceea7c1c9714b6a1906a555a31.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>
2022-05-05 12:22:47 -07:00
dependabot[bot] bce7f49944
Bump HdrHistogram from 2.1.9 to 2.1.12 in /server (#2135)
* Bump HdrHistogram from 2.1.9 to 2.1.12 in /server

Bumps [HdrHistogram](https://github.com/HdrHistogram/HdrHistogram) from 2.1.9 to 2.1.12.
- [Release notes](https://github.com/HdrHistogram/HdrHistogram/releases)
- [Commits](https://github.com/HdrHistogram/HdrHistogram/compare/HdrHistogram-2.1.9...HdrHistogram-2.1.12)

---
updated-dependencies:
- dependency-name: org.hdrhistogram:HdrHistogram
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Updating SHAs

Signed-off-by: dependabot[bot] <support@github.com>

* Update test to match new behavior of HdrHistogram

There was a [change in behavior in HdrHistogram][1] that causes the
tests to fail with the new version. The fix here is to add another value
in the test data set for the failing test, which has the result of
making both versions of HdrHistogram agree on the percentile values.

[1]: 5c7226c4ff

Signed-off-by: Andrew Ross <andrross@amazon.com>

* Remove unnecessary exclusion on third party audit

Signed-off-by: Andrew Ross <andrross@amazon.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Andrew Ross <andrross@amazon.com>
2022-05-05 11:30:12 -05:00
Nick Knize 741445a574
[Remove] TypeFieldMapper (#3196)
Removes last trace of TypeFieldMapper since types have been removed and
NestedPathFieldMapper is now available.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-05 09:35:41 -05:00
Nick Knize 14704b30ca
[Javadocs] add to o.o.monitor,persistance,plugins,repo,script,threadpool,usage,watcher (#3186)
Adds javadocs to classes in the org.opensearch.monitor, persistence, plugins,
repository, script, threadpool, usage, and watcher packages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-04 15:21:35 -07:00
Nick Knize 4d3da00c12
[Javadocs] Add to o.o.disovery, env, gateway, http, ingest, lucene and node pkgs (#3185)
Adds javadocs to classes in the org.opensearch.discovery, env, gateway, http,
ingest, lucene, and node packages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-04 14:32:01 -05:00
Nick Knize 6ca3278f96
[Javadocs] Add to remaining o.o.action classes (#3182)
Adds javadocs to remaining undocumented classes in o.o.action package.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-04 13:35:57 -05:00
Nick Knize 40024fcf71
[Javadocs] add to o.o.cluster (#3170)
Adds javadocs to classes in the o.o.cluster package.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-03 22:18:43 -05:00
Nick Knize c76a4c9014
[Remove] ShrinkAction, ShardUpgradeRequest, UpgradeSettingsRequestBuilder (#3169)
Removes unused ShrinkAction, ShardUpgradeRequest, and
UpgradeSettingsRequestBuilder classes.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-03 22:18:28 -05:00
Nick Knize ad1c8038b0
[Javadocs] add to o.o.action.admin (#3155)
Adds javadocs to classes in package o.o.action.admin.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-03 22:16:48 -05:00
Nick Knize c13b679aad
[Javadocs] add to o.o.bootstrap, cli, and client (#3163)
Adds javadocs to o.o.bootstrap, o.o.cli, and o.o.client packages.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-03 14:44:59 -05:00
Nick Knize 5f531b366e
[Remove] AliasesExistAction (#3149)
With the removal of Transport Client AliasesExistAction is no longer needed and
is removed.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-03 12:05:41 -04:00
Nick Knize 15f035b479
[Remove] TypesExist Action (#3139)
The types exist transport action can be removed now that the TransportClient has
been removed and types support has been removed.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-03 10:26:37 -04:00
Tianli Feng bb870f70c8
Rename ClusterBlock description 'no master' to 'no cluster-manager' (#3133)
* Rename ClusterBlock description 'no master' to 'no cluster-manager'

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Adjust format by spotlessApply task

Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-05-03 10:24:37 -04:00
Tianli Feng f58d98d261
Rename reserved node id '_must_join_elected_master_' to '_must_join_elected_cluster_manager_' that used by in DetachClusterCommand (#3116)
Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-05-02 20:23:11 -07:00
Nick Knize 21468279b2
[Javadoc] Add missing package-info.java files to server (#3128)
In preparation for re-enabling the missingJavadoc gradle task this change adds
in the missing package-info.java files to the server folder. For now general
javadocs are added to these files with the intent to clean up with better
descriptions over time.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-05-02 14:30:53 -05:00
Tianli Feng 017773c62d
Rename BecomeMasterTask to BecomeClusterManagerTask in JoinTaskExecutor (#3099)
Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-04-28 13:57:49 -04:00
Nick Knize d86c88fe59
[Refactor] XContentType to parse Accept or Content-Type headers (#3077)
Refactors XContentType.fromMediaTypeOrFormat to fromMediaType so Accept headers
and Content-Type headers can be parsed separately. This helps in reusing the
same parse logic in for REST Versioning API support.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-04-28 09:58:26 -05:00
Tianli Feng 79eb3b0492
Replace internal usages of 'master' term in 'server/src/main' directory (#2519)
* Replace internal usages of 'master' terminology in server/src/main directory

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Restore rename DISCOVERED_MASTER in ClusterHealthResponse

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Rename two methods in unit tests

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in ClusterState

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in LeaderChecker JoinHelper JoinTaskExecutor

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in more classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in more classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in more classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in more classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in more classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in more classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in DiscoveryNodes classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Replace master word in more classes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Correct mistakes

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Adjust format by spotlessApply task

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Change MASTER__NODE_BOOTSTRAPPED_MSG in test

Signed-off-by: Tianli Feng <ftianli@amazon.com>

* Fix SnapshotDisruptionIT by renaming to cluster-manager

Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-04-27 09:07:35 -04:00
Nick Knize 6b641d2fd2
[Remove] Type from nested fields using new metadata field mapper (#3004)
* [Remove] Type from nested fields using new metadata field mapper

types support is removed yet nested documents use the _type field to store the
path for nested documents. A new _nested_path metadata field mapper is added to
take the place of the _type field in order to remove the type dependency in
nested documents. BWC is handled in the new field mapper to ensure compatibility
with older versions.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>

* pr fixes

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>

* add test to merge same mapping with empty index settings

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-04-26 16:20:10 -04:00
Kartik Ganesh ee7b731975
Adds the replication type index setting, alongside a formal notion of feature flags (#3037)
* This change formalizes the notion of feature flags, and adds a "replication type" setting that will differentiate between document and segment replication, gated by a feature flag. 

Since seg-rep is currently an incomplete implementation, the feature flag ensures that the setting is not visible to users without explicitly setting a system property. We can then continue to merge seg-rep related changes from the feature branch to `main` safely hidden behind the feature flag gate.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Update security policy for testing feature flags

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>

Co-authored-by: Nicholas Walter Knize <nknize@apache.org>
2022-04-25 10:51:02 -07:00
Daniel Doubrovkine (dB.) a389d1e221
Revert "Support task resource tracking in OpenSearch (#2639)" (#3046)
This reverts commit 6517eeca50.

Signed-off-by: dblock <dblock@amazon.com>
Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-04-25 11:08:38 -05:00
Nick Knize 88bc268e29
[Rename] ESTestCase stragglers to OpenSearchTestCase (#3053)
A few places still referenced legacy ESTestCase name. This refactors those
instances to OpenSearchTestCase.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-04-23 16:50:55 -05:00
Nick Knize 3d49ccead2
[Upgrade] Lucene-9.2-snapshot (#2924) 2022-04-21 14:36:01 -07:00
Nick Knize cf78065481
[Remove] MainResponse version override cluster setting (#3031)
OpenSearch 2.0.0 no longer needs HLRC compatibility with legacy clients. This
commit removes all logic to spoof the version as a legacy cluster.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-04-21 17:16:57 -04:00
Peng Huo 03fbca3f50
Add new multi_term aggregation (#2687)
Adds a new multi_term aggregation. The current implementation focuses 
on adding new type aggregates. Performance (latency) is suboptimal in this
iteration, mainly because of brute force encoding/decoding a list of values
into bucket keys. A performance improvement change will be made as a 
follow on.

Signed-off-by: Peng Huo <penghuo@gmail.com>
2022-04-21 09:06:33 -05:00
Tushar Kharbanda 6517eeca50
Support task resource tracking in OpenSearch (#2639)
* Add Task id in Thread Context

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Add resource tracking update support for tasks

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* List tasks action support for task resource refresh

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Handle task unregistration case on same thread

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Add lazy initialisation for RunnableTaskExecutionListener

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Segregate resource tracking logic to a separate service.

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Check for running threads during task unregister

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Moved thread context logic to resource tracking service

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* preserve task id in thread context even after stash

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Add null check for resource tracking service

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Tracking service tests and minor refactoring

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Preserve task id fix with test

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Minor test changes and Task tracking call update

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Fix Auto Queue executor method's signature

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Make task runnable task listener factory implement consumer

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Use reflection for ThreadMXBean

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Formatting

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Replace RunnableTaskExecutionListenerFactory with AtomicReference

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Revert "Use reflection for ThreadMXBean"

This reverts commit cbcf3c525bf516fb7164f0221491a7b25c1f96ec.

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Suppress Warning related to ThreadMXBean

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Add separate method for task resource tracking supported check

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Enabled setting by default

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Add debug logs for stale context id

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Remove hardcoded task overhead in tests

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Bump stale task id in thread context log level to warn

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

* Improve assertions and logging

Signed-off-by: Tushar Kharbanda <tushar.kharbanda72@gmail.com>

Co-authored-by: Tushar Kharbanda <tkharban@amazon.com>
2022-04-21 09:51:44 -04:00
Suraj Singh dbdee30a37
[Type Removal] Remove TypeFieldMapper usage, remove support of `_type` in searches and from LeafFieldsLookup (#3016)
Removes TypeFieldMapper and _type support from searches

Signed-off-by: Suraj Singh <surajrider@gmail.com>
2022-04-20 22:22:11 -05:00
Wenjun Ruan a34d11f15a
Remove usages of MultiTermQuery.setRewriteMethodsetRewriteMethod (#2997)
Remove usages of MultiTermQuery.setRewriteMethod which is removed in 
latest versions of Lucene.

Signed-off-by: ruanwenjun <wenjun@apache.org>
2022-04-20 22:14:44 -05:00
Kartik Ganesh c7c410a063
Refactoring GatedAutoCloseable and moving RecoveryState.Timer (#2965)
* Refactoring GatedAutoCloseable to AutoCloseableRefCounted

This is a part of the process of merging our feature branch - feature/segment-replication - back into main by re-PRing our changes from the feature branch.
GatedAutoCloseable currently wraps a subclass of RefCounted. Segment replication adds another subclass, but this also wraps RefCounted. Both subclasses have the same shutdown hook - decRef. This change makes the superclass less generic to increase code convergence.

The breakdown of the plan to merge segment-replication to main is detailed in #2355
Segment replication design proposal - #2229

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Minor refactoring in RecoveryState

This change makes two minor updates to RecoveryState -
1. The readRecoveryState API is removed because it can be replaced by an invocation of the constructor
2. The class members of the Timer inner class are changed to private, and accesses are only through the public APIs

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Update RecoveryTargetTests to test Timer subclasses deterministically

This change removes the use of RandomBoolean in testing the Timer classes and creates a dedicated unit test for each. The common test logic is shared via a private method.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Move the RecoveryState.Timer class to a top-level class

This will eventually be reused across both replication use-cases - peer recovery and segment replication.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Further update of timer tests in RecoveryTargetTests

Removes a non-deterministic code path around stopping the timer, and avoids assertThat (deprecated)

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Rename to ReplicationTimer

Signed-off-by: Kartik Ganesh <gkart@amazon.com>

* Remove RecoveryTargetTests assert on a running timer

Trying to serialize and deserialize a running Timer instance, and then checking for equality leads to flaky test failures when the ser/deser takes time.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>
2022-04-20 18:02:25 -04:00
Andriy Redko 3b7e654757
Remove JavaVersion, use builtin Runtime.Version to deal with runtime versions (#3006)
Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
2022-04-20 17:14:02 -04:00
Nick Knize 6915df94c3
[Remove] remaining AllFieldMapper references (#3007)
AllFieldMapper was deprecated in legacy 6x. The remaining references are
removed, along with the field mapper and corresponding tests.

Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
2022-04-20 15:05:13 -05:00
Andriy Redko d61d170332
Removed java11 source folders since JDK-11 is the baseline now (#2898)
Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
2022-04-18 10:16:22 -07:00
Ankit Jain d39c18f7fe
Excluding system indices from max shard limit validator (#2894)
* Excluding system indices from max shard limit validator

Signed-off-by: Ankit Jain <jain.ankitk@gmail.com>

* Fixing spotless check violations

Signed-off-by: Ankit Jain <jain.ankitk@gmail.com>

* Fixing NPE due to null isHidden

Signed-off-by: Ankit Jain <jain.ankitk@gmail.com>

* Adding unit tests for shard opening scenario

Signed-off-by: Ankit Jain <jain.ankitk@gmail.com>

* Addressing review comments

Signed-off-by: Ankit Jain <jain.ankitk@gmail.com>
2022-04-14 16:36:01 -07:00
Vacha Shah 452e368bde
Adding a null pointer check to fix index_prefix query (#2879)
* Adding a null pointer check to fix index_prefix query

Signed-off-by: Vacha Shah <vachshah@amazon.com>

* Adding test

Signed-off-by: Vacha Shah <vachshah@amazon.com>
2022-04-14 11:07:22 -07:00
Poojita Raj c4b684d3ae
Add functionality to fast forward local processed checkpoints [segment replication] (#2576) (#2883)
* fix local processed checkpoint update (#2576)

Signed-off-by: Poojita Raj <poojiraj@amazon.com>

* separated tests + wrapper function

Signed-off-by: Poojita Raj <poojiraj@amazon.com>

* moved tests + compareAndSet change

Signed-off-by: Poojita Raj <poojiraj@amazon.com>
2022-04-13 14:00:43 -07:00
Owais Kazi 3c5d997a76
Added a new line linter (#2875)
* Added linter to add new line

Signed-off-by: Owais Kazi <owaiskazi19@gmail.com>

* Fixed new lines

Signed-off-by: Owais Kazi <owaiskazi19@gmail.com>

* Ignore empty files

Signed-off-by: Owais Kazi <owaiskazi19@gmail.com>

* Updated DEVELOPER GUIDE

Signed-off-by: Owais Kazi <owaiskazi19@gmail.com>

* Renamed workflow file

Signed-off-by: Owais Kazi <owaiskazi19@gmail.com>

* Fixed failing tests

Signed-off-by: Owais Kazi <owaiskazi19@gmail.com>
2022-04-13 14:14:18 -04:00
Tianli Feng 08e4a35839
Add request parameter 'cluster_manager_timeout' and deprecate 'master_timeout' - in Ingest APIs and Script APIs (#2682)
- Deprecate the request parameter `master_timeout` that used in Ingest APIs and Script APIs which have got the parameter. 
- Add alternative new request parameter `cluster_manager_timeout`.
- Add unit tests.

Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-04-13 11:13:37 -07:00
opensearch-trigger-bot[bot] 3af4300c3f
Decouple IndexSettings from IncludeExclude (#2860) (#2861)
This change refactors an earlier change to impose a reg-ex size limit on the include/exclude string. Instead of accepting an IndexSettings instance, the class now accepts a integer limit value. This is necessary because the IncludeExclude class is used outside the core codebase, whose use-cases may be unaware of indices and their settings. To ensure that a limit is always imposed, a default limit is defined in the class.

(cherry picked from commit ba1966853e728b153e42be59ba449420e79b09ee)
Signed-off-by: Kartik Ganesh <gkart@amazon.com>

Co-authored-by: Kartik Ganesh <gkart@amazon.com>
2022-04-13 14:13:18 -04:00
Tianli Feng 455fad34ee
Change deprecation message for API parameter value 'master_node' of parameter 'metric' (#2880)
Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-04-12 14:58:19 -07:00
Tianli Feng a89b7e6216
Add request parameter 'cluster_manager_timeout' and deprecate 'master_timeout' - in Snapshot APIs (#2680)
* Deprecate the request parameter `master_timeout` that used in Snapshot APIs which have got the parameter. 
* Add alternative new request parameter `cluster_manager_timeout`.
* Add unit tests.

Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-04-11 20:42:21 -07:00
Tianli Feng ba3ed8a9cb
Add request parameter 'cluster_manager_timeout' and deprecate 'master_timeout' - in Index Template APIs (#2678)
- Deprecate the request parameter `master_timeout` that used in Index Template APIs which have got the parameter. 
(The other Index APIs are addressed in PR https://github.com/opensearch-project/OpenSearch/pull/2660) 
- Add alternative new request parameter `cluster_manager_timeout`.
- Add unit tests.
Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-04-11 17:29:06 -07:00
Tianli Feng ba8657aca5
Change deprecation message for REST API parameter 'master_timeout' to specify the version of removal (#2863)
Signed-off-by: Tianli Feng <ftianli@amazon.com>
2022-04-11 15:59:04 -07:00
Kartik 2d89bc7c61
Updates to the large string reg-ex check (#2814)
* Updates to the large string reg-ex check

Removed the null-case for IndexSettings since this only occurs in tests. The tests now use a dummy Index Setting.
This change also fixes a bug with the base case handling of max regex length in the check.

Signed-off-by: Kartik Ganesh <gkart@amazon.com>
2022-04-07 18:12:33 -07:00