pedestal 2026-04-04

Are connectors added in 0.8 exclusively for HTTP sources or should we expect them to also work for other sources of stimulus such as kafka, SQS, etc?

The connector is really two things: a Pedestal connector (effectively, the part that runs the interceptor chain and provides some semantics, such as :request and :response maps), and the Network connector that is anything outside -- usually HTTP connections via Jetty or HttpKit. However, the same pattern works well for other actors, such as queues. The contract is minimal - a constructor function that accepts the connector map plus a network connector-specific options map, and returns a Pedestal connector: https://github.com/pedestal/pedestal/blob/master/service/src/io/pedestal/service/protocols.clj#L32 . The connector protocol is mostly concerned with the lifecycle (how to start, how to stop). This protocol and general approach is somewhat oriented towards Ring-like request processing (especially with respect to the test-request method).

Thanks for the quick response @hlship !

Should the docstring explicitly call out HTTP if the protocol is generic?

Maybe that can be amended. I have a problem with docs that are too abstract from their actual usage ... tends to make them impenetrable to new readers. So I'd rather say "this is oriented around HTTP request handling, but can be adapted for other uses" than something so generic, you can't tell why it exists.

That completely makes sense, just wanted to ensure I wasn't barking up the wrong tree with some off-label use.