If you find a gap in your testing process that no k6 extension can fix, consider building your own extension.
- Create an Output extension to process the metrics emitted by k6 or publish them to unsupported backend stores.
Anyone who can use the command line to edit files and install software should be able to follow along. But, if you want to create an extension for more than the purposes of demonstration, there's some background knowledge you should have:
If you maintain a public xk6 repository, the community appreciates that it stays up to date with the latest k6 APIs.
Avoid unneeded work
These actions may save you the trouble of building a whole new extension when its not needed.
- Confirm that a similar extension doesn't already exist for your use case. Take a look at the Extensions listing and the xk6 topic on GitHub.
- Prefer generic solutions. For example, if you can test a system with a generic protocol like MQTT, prefer xk6-mqtt over a new extension for some custom protocol.