Retry limit exceeded at at

JDK Bug System | John Jiang | 8 months ago
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Currently, property affects not only redirection limit, but also re-connection limit. That may be confusing. Redirection and re-connection have different meanings. Please consider the below test: import; import; import; import; import; public class SimpleRedirectTest { public static void main(String[] args) throws Exception { System.setProperty("", "0"); String url = "..."; HttpClient client = HttpClient.create().followRedirects(Redirect.ALWAYS).build(); HttpRequest request = client.request(new URI(url)).GET(); HttpResponse<String> response = request.response(HttpResponse.BodyHandler.discard("BODY")); System.out.println(response.statusCode()); } } The test raises the following exception: Exception in thread "main" Retry limit exceeded at at at SimpleRedirectTest.main( The exception is thrown while connecting the server, but the test only focus on redirection. It would be better use two different properties for redirection limit and re-connection limit.

    JDK Bug System | 8 months ago | John Jiang Retry limit exceeded at at

    Root Cause Analysis


      Retry limit exceeded at at

      at SimpleRedirectTest.main()
    2. Unknown
      1. SimpleRedirectTest.main(
      1 frame