Skip to content

Instantly share code, notes, and snippets.

@alexolinux
Created March 5, 2024 20:49
Show Gist options
  • Select an option

  • Save alexolinux/c67b7094c7f2a123e57c35aef5925cf0 to your computer and use it in GitHub Desktop.

Select an option

Save alexolinux/c67b7094c7f2a123e57c35aef5925cf0 to your computer and use it in GitHub Desktop.
Example Run: locust -f locust.py -H http://localhost -P 8089
from locust import HttpUser, task, between
class MyUser(HttpUser):
wait_time = between(1, 5) # Time between requests in seconds
@task
def my_task(self):
# Replace api-endpoint
self.client.get("/api-endpoint")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment