I’m watching the Performance Testing section of The Ultimate Django Series: Part 3 course, and my /store/carts/ endpoint is taking too long when you make a POST request.
The times are above 2000 ms while in other endpoint requests the maximum is around 100 ms.
Debug Toolbar and Silk are turned off in this results.
I’ve noticed that if I make a manual post, it does not take as long as it seems in Locust, there are two similar queries, I think one is coming from getting the items, which doesn’t exist at this moment, and the other one from calculating the total price in the CartSerializer. I don’t know how to reduce that to one query but I don’t think that’s the problem.
Now, if I turn on Silk and repeat the test, it doesn’t seem to take as long as it appears on Locust.
I don’t know what’s the problem and I don’t know if it’s important since it appears to be no problems in Silk.