aleph

Matthew Davidson 2022-04-28T08:45:54.147589Z

@lkorogodski Not exactly. When starting the server, you could pass in :raw-stream? true , which will prevent Aleph from turning the netty ByteBuf objects into an InputStream, but instead, you’ll get a Manifold stream of ByteBufs. If you want to aggregate the whole request body into a byte[], you probably want to use something like clj-commons.byte-streams/to-byte-array . The byte-streams library was built to work with the underlying streams of Aleph. Also, check out the examples/ subdirectory to see uses of byte-streams in action.

Leonid Korogodski 2022-04-28T13:06:19.681819Z

Ok, thanks. I just wanted to spare myself some pain with the middleware that reads the response body. Came across a malli bug when validating the payload.

👍 1
Leonid Korogodski 2022-04-28T13:07:28.956629Z

Post-validation, the body became nil .