Introducing Locust load testing: Event-driven, test-as-code performance testing suite

Published: Aug 22, 2024
By: Erica Lindberg

Open Core Ventures (OCV) is proud to announce the launch of Locust Technologies, a load testing solution built on top of the open-source project Locust. Founder and CTO Lars Homberg is a long-time contributor and the current maintainer of the open-source project. “Lars’ role as the lead maintainer of the project combined with his entrepreneurial passion for building a company around  performance testing makes him a great fit for the company,” said Betty Ma, COO at OCV. “We’re looking forward to seeing how he evolves Locust into an enterprise-ready load testing tool.” Contributor Andrew Baldwin has also joined the company as Locust’s first full-time hire. Andrew recently updated Locust’s open-source GUI, giving the project a modernized user interface. 

Locust’s primary commercial offering will be hosted load generation that takes on the infrastructure burden for customers. “Simulating load requires special infrastructure to ensure tests are precise and repeatable,” said Lars. “We will offer hosted load generation so customers don’t need to manage that. Our service is available whenever you need it, and it comes with professional support.” Lars and the team plan to continue to improve Locust’s open-source UI and add advanced reporting capabilities. “When you do big load tests, you need smart analysis to determine if the results were good enough. And you need the ability to drill down and trace where things went wrong, even if it was only 1 in a thousand requests that failed or were too slow,” said Lars. “Our reporting solution will provide that, with little to no effort from the customer.” 

With the initial $2M funding from OCV, Lars plans to hire a small team of Python engineers to continue to improve the open-source core and to develop enterprise-ready features.

Developer-friendly load testing 

Unlike most performance testing tools, Locust is code-based and event-driven. “Your performance tests are expressed in regular Python code, which makes it very flexible,” said Lars. “Most load testing tools take a configuration approach and you are locked into the default framework of the tool. For example, if you want to send a certain request 10 times, you would use the built-in concepts of the load testing tool to do that rather than just write a for-loop. It’s not very flexible.” With Locust, you maintain all the power and flexibility of  Python, allowing you to create advanced scenarios and test complex systems. 

To keep this load-testing-as-code approach simple while still maintaining scalability, Locust uses gevent, a coroutine-based Python library. Thanks to gevent, Locust can scale simulations to tens of thousands of users in a single process. According to the Test Guild’s 16 Top Load Testing Software Tools for 2024, one user claimed that Locust’s event-based approach used 70% fewer resources than JMeter’s thread-based approach. “Locust strikes a balance between great performance and flexibility,” said Sid Sijbrandij, General Partner at OCV. “While some tools are more oriented toward throwing simple requests at a server, Locust can handle complex scenarios at scale.”

With more services coming online, it’s more important than ever that companies know their sites can handle large traffic and resource spikes. Locust aims to make it easy to test and understand performance for all types of scenarios. By building a reporting solution, Locust aims to help users quickly understand what went wrong. “Having a load testing tool integrated with a monitoring solution is a huge advantage,” said Lars. “We plan to use Open Telemetry, the industry standard for observability.” Built-in tracing will help Locust deliver insights to help customers quickly uncover and remediate system bottlenecks. 

Starting an open-core company 

The open core business model is built on the idea that companies improve the existing open source project while developing value-added commercial features and functionality specifically tailored to business (versus individual user) needs. For Lars, starting an open-core company has allowed him to take his role as maintainer to the next level. 

Originally discovering the project while working as a consultant, Lars took over as maintainer in 2019. “I used Locust a lot in my work and found it a lot more flexible than other load testing tools, both open source and proprietary,” said Lars. 

“What originally motivated me to become involved in the project is probably the most common reason: I needed something that wasn’t already there. After contributing a few times, I started helping others with their questions and issues, and by that time I was hooked. I find contributing to open source personally fulfilling, and it’s always fun to hear about people using Locust in some new and creative way.”

When OCV reached out it was perfect timing. “After working as a consultant for a long time I wanted something new,” said Lars. “I’m excited to be back in startup land and building again.”