Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test failure v2.0.0#mixedClusterTest o.o.backwards.ExceptionIT caused by 'GET _cat/master' deprecation warning #2759

Closed
tlfeng opened this issue Apr 4, 2022 · 0 comments · Fixed by #2767
Labels
bug Something isn't working :test Adding or fixing a test v2.1.0 Issues and PRs related to version 2.1.0 v3.0.0 Issues and PRs related to version 3.0.0

Comments

@tlfeng
Copy link
Collaborator

tlfeng commented Apr 4, 2022

Is your feature request related to a problem? Please describe.
The test ExceptionIT.testOpenSearchException() is broken, because it uses a deprecated REST API path _cat/master.
Code: https://github.com/opensearch-project/OpenSearch/blob/1.3.1/qa/mixed-cluster/src/test/java/org/opensearch/backwards/ExceptionIT.java#L50
The test failure was found in #2744 (comment)

The test uses High-Level-Rest-Client, those tests treat warning as failure, and using deprecated REST API will cause deprecation warning. The path _cat/master was deprecated in PR #2404 / commit 3da9eb6

Describe the solution you'd like
Either:

  1. Allow deprecation warning in the specific test
  2. Avoid calling GET _cat/master in all versions or version >=2.0 in this test

Describe alternatives you've considered
n/a

Additional context
Related to PR #2702, which is a temporary way to make HLRC allow the deprecation warning.
Related to issue #1549 which deprecate the REST API with master terminology.

test failure detail:

REPRODUCE WITH: ./gradlew ':qa:mixed-cluster:v2.0.0#mixedClusterTest' --tests "org.opensearch.backwards.ExceptionIT.testOpensearchException" -Dtests.seed=D5F130EEE0745C2A -Dtests.security.manager=true -Dtests.jvm.argline="-XX:TieredStopAtLevel=1 -XX:ReservedCodeCacheSize=64m" -Dtests.locale=ru-RU -Dtests.timezone=CNT -Druntime.java=17

org.opensearch.backwards.ExceptionIT > testOpensearchException FAILED
    org.opensearch.client.WarningFailureException: method [GET], host [http://127.0.0.1:33867], URI [_cat/master?h=id], status line [HTTP/1.1 200 OK]
    Warnings: [[GET /_cat/master] is deprecated! Use [GET /_cat/cluster_manager] instead.]
    TDvNsrtlRN-XVfX6m5x5Dw
        at __randomizedtesting.SeedInfo.seed([D5F130EEE0745C2A:7A08F576466769D0]:0)
        at app//org.opensearch.client.RestClient.convertResponse(RestClient.java:346)
        at app//org.opensearch.client.RestClient.performRequest(RestClient.java:320)
        at app//org.opensearch.client.RestClient.performRequest(RestClient.java:295)
        at app//org.opensearch.backwards.ExceptionIT.logClusterNodes(ExceptionIT.java:50)
        at app//org.opensearch.backwards.ExceptionIT.testOpensearchException(ExceptionIT.java:28)
@tlfeng tlfeng added enhancement Enhancement or improvement to existing feature or request v2.0.0 Version 2.0.0 :test Adding or fixing a test labels Apr 4, 2022
@tlfeng tlfeng added bug Something isn't working v2.1.0 Issues and PRs related to version 2.1.0 v3.0.0 Issues and PRs related to version 3.0.0 and removed enhancement Enhancement or improvement to existing feature or request v2.0.0 Version 2.0.0 labels Apr 5, 2022
@tlfeng tlfeng changed the title Replace 'GET _cat/master' request in ExceptionIT class of mixed-cluster BWC test Test failure v2.0.0#mixedClusterTest o.o.backwards.ExceptionIT caused by 'GET _cat/master' deprecation warning Apr 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working :test Adding or fixing a test v2.1.0 Issues and PRs related to version 2.1.0 v3.0.0 Issues and PRs related to version 3.0.0
Projects
None yet
1 participant