Stubby is a stubbing platform providing preset responses to HTTP requests, that was built to accomodate operations-specific troubleshooting requirements for a large-scale mobile portal.
Its primary use case is to emulate slow or badly-responding backend services. In a large-scale production environment, where the applications often failed due to downstream services which were unreliable or buggy, it proved itself extremely useful to speed up troubleshooting.
Some usage examples, usually reproducing failing scenarios:
- to figure out how our applications handled downstream request timeouts
- when downstream HTTP response headers appeared to be the cause of an issue
- when provided content appeared to be invalid, it allowed for rapid prototyping of possible solutions
- to manipulate caching headers to investigate why some issues were occurring
However, due to its nature it can be used for load testing too, it handles quite a bit of load and can be scaled out quite easily.
Stubs can be customized in many ways:
- custom HTTP response code
- unlimited HTTP response headers
- override default headers, like content-length, content-type, cache-control, etc.
- configurable response delay, from instant responses to randomly-changing delays in an interval, or fixed delays
- support for any kind of HTTP payload, binary or text
It comes with built-in documentation and user manual.
Stubby was built using the Grails framework (Java), runs on Tomcat with a MySQL database backend.