atlassian/gostatsd — reverse-engineered prompt

Reverse engineered prompt

GitHub

Build me a fast Go statsd service that works like Etsy statsd, but supports tagged metrics. I want it to listen for normal statsd packets over UDP, and also support a Unix socket when configured. It should handle counters, gauges, timers, sets, and events, aggregate them on a regular flush interval, then send the results to pluggable backends.

Please include a ready to run server binary with a clear command line help screen, sensible defaults, and config options for things like listen address, flush interval, namespace, percentiles, worker counts, metric expiry, and logging bad input. It should have a standalone mode that processes and flushes metrics, plus a forwarder mode for relaying metrics.

Also make it usable as a library so someone can build a custom statsd server with their own backend. Add a simple stdout backend for local testing, Docker support for trying it out, and enough tests to trust the parser, tags, aggregation, and metric expiry behavior.

Want more depth? Deep Reverse