samuel025/DRMQ — reverse-engineered prompt
Reverse engineered prompt
Build me a Java 17 Maven project for a distributed reliable message queue called DRMQ.
I want a broker that can run as one local node for testing or as a small cluster where nodes elect a leader and replicate messages using Raft, so messages survive crashes and the system avoids split brain. Producers should be able to send messages to topics over a custom TCP protocol, and consumers should be able to read them either as a group where work is automatically shared, or as a single consumer that can choose and commit offsets manually for replay.
Please include durable disk storage with a write ahead log, client libraries for producers and consumers, reconnect and failover behavior, a simple interactive command line producer and consumer for testing, Prometheus style metrics, and integration tests that prove sending, consuming, failover, replay, and consumer group redelivery work. Make it easy to build with Maven and run a one node or three node setup from the command line.
Want more depth? Deep Reverse