You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "ajantha-bhat (via GitHub)" <gi...@apache.org> on 2023/03/02 15:43:55 UTC

[GitHub] [iceberg] ajantha-bhat opened a new issue, #6988: flaky test: TestRESTCatalog > testCatalogTokenRefreshFailsAndUsesCredentialForRefresh()

ajantha-bhat opened a new issue, #6988:
URL: https://github.com/apache/iceberg/issues/6988

   ### Apache Iceberg version
   
   None
   
   ### Query engine
   
   None
   
   ### Please describe the bug 🐞
   
   CI run with dummy PR:
   https://github.com/apache/iceberg/actions/runs/4315439240/jobs/7529817581
   
   ```
   TestRESTCatalog > testCatalogTokenRefreshFailsAndUsesCredentialForRefresh() FAILED
       org.mockito.exceptions.verification.TooFewActualInvocations: 
       rESTCatalogAdapter.execute(
           POST,
           "v1/oauth/tokens",
           <any>,
           <custom argument matcher>,
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {"Authorization" = "***"},
           <any>
       );
       Wanted 2 times:
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:374)
       But was 1 time:
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.postForm(RESTCatalogAdapter.java:455)
           at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:374)
           at org.apache.iceberg.rest.TestRESTCatalog.testCatalogTokenRefreshFailsAndUsesCredentialForRefresh(TestRESTCatalog.java:1497)
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


[GitHub] [iceberg] ajantha-bhat commented on issue #6988: flaky test: TestRESTCatalog > testCatalogTokenRefreshFailsAndUsesCredentialForRefresh()

Posted by "ajantha-bhat (via GitHub)" <gi...@apache.org>.
ajantha-bhat commented on issue #6988:
URL: https://github.com/apache/iceberg/issues/6988#issuecomment-1452103443

   same test Failed again with a different error
   https://github.com/apache/iceberg/actions/runs/4315717107/jobs/7530487403
   
   ```
   TestRESTCatalog > testCatalogTokenRefreshFailsAndUsesCredentialForRefresh() FAILED
       Argument(s) are different! Wanted:
       rESTCatalogAdapter.execute(
           GET,
           "v1/namespaces/ns/tables/table",
           <any>,
           <any>,
           class org.apache.iceberg.rest.responses.LoadTableResponse,
           {"Authorization" = "***"},
           <any>
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:374)
       Actual invocations have different arguments:
       rESTCatalogAdapter.postForm(
           "v1/oauth/tokens",
           {"grant_type" = "client_credentials", "client_id" = "catalog", "client_secret" = "secret", "scope" = "catalog"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.auth.OAuth2Util.fetchToken(OAuth2Util.java:191)
       rESTCatalogAdapter.execute(
           POST,
           "v1/oauth/tokens",
           null,
           {"grant_type" = "client_credentials", "client_id" = "catalog", "client_secret" = "secret", "scope" = "catalog"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.postForm(RESTCatalogAdapter.java:455)
       rESTCatalogAdapter.handleRequest(
           TOKENS,
           {},
           {"grant_type" = "client_credentials", "client_id" = "catalog", "client_secret" = "secret", "scope" = "catalog"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:384)
       rESTCatalogAdapter.get(
           "v1/config",
           {},
           class org.apache.iceberg.rest.responses.ConfigResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$DefaultErrorHandler@3ad80206
       );
       -> at org.apache.iceberg.rest.RESTSessionCatalog.fetchConfig(RESTSessionCatalog.java:791)
       rESTCatalogAdapter.execute(
           GET,
           "v1/config",
           {},
           null,
           class org.apache.iceberg.rest.responses.ConfigResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$DefaultErrorHandler@3ad80206
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.get(RESTCatalogAdapter.java:440)
       rESTCatalogAdapter.handleRequest(
           CONFIG,
           {},
           null,
           class org.apache.iceberg.rest.responses.ConfigResponse
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:384)
       rESTCatalogAdapter.close(
       
       );
       -> at org.apache.iceberg.rest.RESTSessionCatalog.initialize(RESTSessionCatalog.java:162)
       rESTCatalogAdapter.postForm(
           "v1/oauth/tokens",
           {"grant_type" = "urn:ietf:params:oauth:grant-type:token-exchange", "scope" = "catalog", "subject_token" = "client-credentials-token:sub=catalog", "subject_token_type" = "urn:ietf:params:oauth:token-type:access_token"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.auth.OAuth2Util.refreshToken(OAuth2Util.java:145)
       rESTCatalogAdapter.execute(
           POST,
           "v1/oauth/tokens",
           null,
           {"grant_type" = "urn:ietf:params:oauth:grant-type:token-exchange", "scope" = "catalog", "subject_token" = "client-credentials-token:sub=catalog", "subject_token_type" = "urn:ietf:params:oauth:token-type:access_token"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.postForm(RESTCatalogAdapter.java:455)
       rESTCatalogAdapter.postForm(
           "v1/oauth/tokens",
           {"grant_type" = "urn:ietf:params:oauth:grant-type:token-exchange", "scope" = "catalog", "subject_token" = "client-credentials-token:sub=catalog", "subject_token_type" = "urn:ietf:params:oauth:token-type:access_token"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.auth.OAuth2Util.refreshToken(OAuth2Util.java:145)
       rESTCatalogAdapter.get(
           "v1/namespaces/ns/tables/table",
           {"snapshots" = "all"},
           class org.apache.iceberg.rest.responses.LoadTableResponse,
           org.apache.iceberg.rest.RESTSessionCatalog$$Lambda$800/545707113@2b4675db,
           org.apache.iceberg.rest.ErrorHandlers$TableErrorHandler@1737834
       );
       -> at org.apache.iceberg.rest.RESTSessionCatalog.loadInternal(RESTSessionCatalog.java:[287](https://github.com/apache/iceberg/actions/runs/4315717107/jobs/7530487403#step:6:288))
       rESTCatalogAdapter.execute(
           POST,
           "v1/oauth/tokens",
           null,
           {"grant_type" = "urn:ietf:params:oauth:grant-type:token-exchange", "scope" = "catalog", "subject_token" = "client-credentials-token:sub=catalog", "subject_token_type" = "urn:ietf:params:oauth:token-type:access_token"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.postForm(RESTCatalogAdapter.java:455)
       rESTCatalogAdapter.postForm(
           "v1/oauth/tokens",
           {"grant_type" = "urn:ietf:params:oauth:grant-type:token-exchange", "scope" = "catalog", "subject_token" = "client-credentials-token:sub=catalog", "subject_token_type" = "urn:ietf:params:oauth:token-type:access_token"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {"Authorization" = "Basic Y2F0YWxvZzpzZWNyZXQ="},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.auth.OAuth2Util.refreshToken(OAuth2Util.java:145)
       rESTCatalogAdapter.execute(
           POST,
           "v1/oauth/tokens",
           null,
           {"grant_type" = "urn:ietf:params:oauth:grant-type:token-exchange", "scope" = "catalog", "subject_token" = "client-credentials-token:sub=catalog", "subject_token_type" = "urn:ietf:params:oauth:token-type:access_token"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse,
           {"Authorization" = "Basic Y2F0YWxvZzpzZWNyZXQ="},
           org.apache.iceberg.rest.ErrorHandlers$OAuthErrorHandler@69860811
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.postForm(RESTCatalogAdapter.java:455)
       rESTCatalogAdapter.get(
           "v1/namespaces/ns/tables/table",
           {"snapshots" = "all"},
           class org.apache.iceberg.rest.responses.LoadTableResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$TableErrorHandler@1737834
       );
       -> at org.apache.iceberg.rest.RESTClient.get(RESTClient.java:96)
       rESTCatalogAdapter.execute(
           GET,
           "v1/namespaces/ns/tables/table",
           {"snapshots" = "all"},
           null,
           class org.apache.iceberg.rest.responses.LoadTableResponse,
           {"Authorization" = "***"},
           org.apache.iceberg.rest.ErrorHandlers$TableErrorHandler@1737834
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.get(RESTCatalogAdapter.java:440)
       rESTCatalogAdapter.handleRequest(
           LOAD_TABLE,
           {"snapshots" = "all", "namespace" = "ns", "table" = "table"},
           null,
           class org.apache.iceberg.rest.responses.LoadTableResponse
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:384)
       rESTCatalogAdapter.handleRequest(
           TOKENS,
           {},
           {"grant_type" = "urn:ietf:params:oauth:grant-type:token-exchange", "scope" = "catalog", "subject_token" = "client-credentials-token:sub=catalog", "subject_token_type" = "urn:ietf:params:oauth:token-type:access_token"},
           class org.apache.iceberg.rest.responses.OAuthTokenResponse
       );
       -> at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:384)
           at org.apache.iceberg.rest.RESTCatalogAdapter.execute(RESTCatalogAdapter.java:[374](https://github.com/apache/iceberg/actions/runs/4315717107/jobs/7530487403#step:6:375))
           at org.apache.iceberg.rest.TestRESTCatalog.testCatalogTokenRefreshFailsAndUsesCredentialForRefresh(TestRESTCatalog.java:1523)
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


[GitHub] [iceberg] danielcweeks closed issue #6988: flaky test: TestRESTCatalog > testCatalogTokenRefreshFailsAndUsesCredentialForRefresh()

Posted by "danielcweeks (via GitHub)" <gi...@apache.org>.
danielcweeks closed issue #6988: flaky test: TestRESTCatalog > testCatalogTokenRefreshFailsAndUsesCredentialForRefresh()
URL: https://github.com/apache/iceberg/issues/6988


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


[GitHub] [iceberg] ajantha-bhat commented on issue #6988: flaky test: TestRESTCatalog > testCatalogTokenRefreshFailsAndUsesCredentialForRefresh()

Posted by "ajantha-bhat (via GitHub)" <gi...@apache.org>.
ajantha-bhat commented on issue #6988:
URL: https://github.com/apache/iceberg/issues/6988#issuecomment-1452099059

   cc: @nastra 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org