This is not currently possible with Finatra. Finatra will not call your route until the entire request has been received and memorized into a ChannelBuffer. In addition, Finatra also reads the request as a single chunk so you cannot receive any body longer than ~2MB. Setting com.twitter.finatra.config.maxRequestSize to something higher than 2048 will cause it to crash at runtime.

I've switched to Play Framework using the NettyServer embed and "String Interpolating Routing DSL" to retain a DSL similar to Finatra.

Related Query

More Query from same tag