Search code examples
pythondjangowebfaction

How to load test Django API?


I'm putting the finishing touches on my Django-based Webfaction-hosted server. It has a REST API that will deliver content to mobile devices, and will accept POST requests from a different source every few minutes. So far, the POST part is going fine -- it's been accepting data for a week now with no major issues.

However, I'm worried about what happens when I release the mobile app - I expect a fair number of users and I don't want to run into a dead app if my API can't handle the load from all the GET requests.

How do I load test my Django API? Are there tools available online to simulate several hundred GET requests at once, or should I build a test from scratch?


Solution

  • You can check out Locust

    This is an open source load testing tool and will help you test your api as well.