Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Works as Designed
    • Affects Version/s: 5.0.8
    • Fix Version/s: None
    • Component/s: Web:Client

      Description

      I discovered an issue with first request and shared state in WebClient. In short, the first request takes a lot of time to complete (~300 ms on my machine) compared to the following requests (~5 ms).  The performance compared to RestTemplate is a bit problematic in case of integration tests with WireMock. I described more details in a repository with code examples: https://github.com/slonka/webclient-debug

       

      I'd be grateful for some insights whether this can be improved via configuration or changes to WebClient source code that would initialize static fields eagerly before first request.

       

      Please let me know if I can provide any more information.

        Attachments

          Activity

            People

            • Assignee:
              bclozel Brian Clozel
              Reporter:
              krzysztofslonka Krzysztof Slonka
              Last updater:
              Spring Issuemaster
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                1 year, 1 week, 4 days ago