$ show noboomu/proteus
Proteus is a high-performance Java REST API framework built on Undertow. At runtime it compiles JAX-RS/Swagger-annotated controller methods into dedicated Undertow handlers using JavaPoet and SourceBuddy, then dispatches requests through a custom routing handler. The central ProteusApplication class wires Guice modules, services, controllers, configuration, and the Undertow server; controllers return ServerRequest/ServerResponse wrappers that support async futures, content negotiation, file uploads, redirects, and JSON/XML serialization. The project is split into proteus-core and proteus-openapi, with the latter extending the Swagger JAX-RS reader to understand Proteus-specific response types and serving Swagger UI/ReDoc documentation.
The LLM identified 3 files worth highlighting for reuse:
A comprehensive, self-contained file-extension-to-MIME-type registry with lookup utilities. It is not coupled to Proteus internals, so an HTTP server, file upload service, or CLI tool could reuse it directly for content-type detection and negotiation.
Static parameter extraction helpers that convert Undertow exchange values into strongly typed Java objects: primitives, Optionals, collections, maps, files, paths, byte buffers, and JSON/XML deserialized bodies. The type-handling cache and support for many shapes make it a reusable request-binding utility outside the framework.
A custom Undertow predicate and predicate builder that rejects requests over a configured content length before the main handler runs. It is a small, self-contained abuse-prevention component and demonstrates how to extend Undertow's predicate system cleanly.