-
-
Notifications
You must be signed in to change notification settings - Fork 213
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
Requests are very slow (~2.1 sec) - bad performance #554
Comments
This may be something from my local machine. It seems the tests ran by the repos CI/CD run fast. I've tested it also on our CI/CD and they run fast. |
@narcis-sy did you ever figure out your local issue? I realized I was running into a similar issue when I placed timeout policies on my http client requests and started seeing errors in testing. |
@kaiserbergin Nope :( I happens just locally and just for some people (Win10). I tried disabling firewall everything.. still takes time, idk why. |
I am seeing the same problem - the first request to WireMock from a I am also on Win10, and am using .NetCore 3.1 and 5.0. I went digging into it, and it turns out to be something to do with requesting "any" IP address when configuring Kestrel options in Making that change reduces the execution time of any single WireMockServerTest from >2 seconds to 200-300ms. Running the WireMock test suite itself is fairly dramatic. From:
To:
Note - those test times are misleading, they seem to be the cumulative count of all tests, even though the tests are running concurrently. @StefH - I will create a PR for my fix to this and it would be great if you're happy to accept it. Please be aware that I am only able to test this on my Windows 10 machine. All of the various flavours do pass all their tests (net452 through netcore5.0) here, but I am not able to verify it on Mac/linux/elsewhere. |
Describe the bug
Requests to the server are handled very slowly, ~2.1 sec for a simple get.
Expected behavior:
Given that the server is in memory I would expect a response time of less de 50ms.
Test to reproduce
Simple add a stopwatch in any of the tests in https://github.com/WireMock-Net/WireMock.Net/blob/master/test/WireMock.Net.Tests/WireMockServerTests.cs
I only count the request time, not the actual start of the server.
This gives 2.1 sec. I've measured the
WireMockMiddleware
and it takes 62ms. So something is lost on the way.Other related info
Using xunit for testing
The text was updated successfully, but these errors were encountered: