* 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>
- 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>
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>
* 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>
- 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>
* Upgrade to Apache Commons Logging 1.2
Signed-off-by: Yoann Rodière <yoann@hibernate.org>
* Clarify that Apache HTTP/commons-* dependencies are not just for tests
Signed-off-by: Yoann Rodière <yoann@hibernate.org>
* 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>
* Bugfix to guard against stack overflow errors caused by very large reg-ex input
This change fixes a code path that did not properly impose the index-level max_regex_length limit. Therefore, it was possibly to provide ar arbitrarily large string as the include/exclude reg-ex value under search aggregations. This exposed the underlying node to crashes from a StackOverflowError, due to how the Lucene RegExp class processes strings using stack frames.
Signed-off-by: Kartik Ganesh <gkart@amazon.com>
* Adding integration tests for large string RegEx
Signed-off-by: Kartik Ganesh <gkart@amazon.com>
* Spotless
Signed-off-by: Kartik Ganesh <gkart@amazon.com>
* Fix issue that deprecated setting 'cluster.initial_master_nodes' is not identified during node bootstrap
Signed-off-by: Tianli Feng <ftianli@amazon.com>
* Restore a variable name
Signed-off-by: Tianli Feng <ftianli@amazon.com>
* Bump geoip2 from 2.16.1 to 3.0.1 in /modules/ingest-geoip
Bumps [geoip2](https://github.com/maxmind/GeoIP2-java) from 2.16.1 to 3.0.1.
- [Release notes](https://github.com/maxmind/GeoIP2-java/releases)
- [Changelog](https://github.com/maxmind/GeoIP2-java/blob/main/CHANGELOG.md)
- [Commits](https://github.com/maxmind/GeoIP2-java/compare/v2.16.1...v3.0.1)
---
updated-dependencies:
- dependency-name: com.maxmind.geoip2:geoip2
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
* Updating SHAs
Signed-off-by: dependabot[bot] <support@github.com>
* Fix breaking change with geoip2 version 3.0.1.
Signed-off-by: Marc Handalian <handalm@amazon.com>
* Fix precommit failures caused by ignoreMissingClasses check.
Precommit is failing because forbiddenApis was configured to ignore missing classes
that are present.
Signed-off-by: Marc Handalian <handalm@amazon.com>
* Change asn in GeoIpProcessorTests from int to long.
Signed-off-by: Marc Handalian <handalm@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: Marc Handalian <handalm@amazon.com>
- Deprecate the request parameter `master_timeout` that used in Index APIs which have got the parameter.
(except index template APIs, which is addressed in PR https://github.com/opensearch-project/OpenSearch/pull/2678)
- Add alternative new request parameter `cluster_manager_timeout`.
- Add unit tests.
Signed-off-by: Tianli Feng <ftianli@amazon.com>
This change swaps the order of the task to first check for no pointless exclusions.
If not caught first these will be thrown inside of the bogusExcludesCount block that logs a
useless error message.
Signed-off-by: Marc Handalian <handalm@amazon.com>
* Bump jcodings from 1.0.44 to 1.0.57 in /libs/grok
Bumps [jcodings](https://github.com/jruby/jcodings) from 1.0.44 to 1.0.57.
- [Release notes](https://github.com/jruby/jcodings/releases)
- [Commits](https://github.com/jruby/jcodings/compare/jcodings-1.0.44...jcodings-1.0.57)
---
updated-dependencies:
- dependency-name: org.jruby.jcodings:jcodings
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>
* Fix forbiddenApisCheck for libs/grok.
This change removes the ignoreMissingClasses block of the thirdPartyAudit check.
This class is not missing, so the check causes failures.
Signed-off-by: Marc Handalian <handalm@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: Marc Handalian <handalm@amazon.com>
- Deprecate the request parameter `master_timeout` that used in Cluster 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>
Changes version comparison logic to only translate major version when
comparing with legacy 7x versions. This is needed beginning in 2.0 so
that when running 2.0+ versions in bwc mode for 3.0+ upgrades, node
versions no longer have to translate major version or spoof to legacy
versions.
Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
Temporarily build rest client with setStrictDeprecationMode(false) to allow
deprecation warning in HLRC tests while master_timeout parameters is
being refactored.
Signed-off-by: Tianli Feng <ftianli@amazon.com>
Apply the change of CAT Nodes API in PR #2435 to other applicable CAT APIs.
- Deprecate the request parameter `master_timeout` that used in many CAT APIs.
- Add alternative new request parameter `cluster_manager_timeout`.
- Add unit tests.
Signed-off-by: Tianli Feng <ftianli@amazon.com>