You need to use io.undertow.server.HttpServerExchange#setMaxEntitySize (just set it to zero). This has to be done before you start reading from the stream.

If you are using Servlet and need to get hold of the current exchange you can use

io.undertow.servlet.handlers.ServletRequestContext.requireCurrent().getExchange()

Stuart



On Mon, Jul 25, 2016 at 11:22 PM, David Robison <david.robison@psgglobal.net> wrote:

I have created a REST interface that receives a continuous stream of JPEGs from a video decoder for the purpose of writing then to a disk file.  The service is defined as:

 

@POST

@Consumes("*/*")

@Path("/Receive/{videoId}")

public Response receiveVideo(@PathParam("videoId") String videoId, InputStream content)

 

Everything works fine up until it reaches the max-post-size and then the connection is terminated. Is there any way to disable the max-post-size when streaming video to a REST interface?

 

Thanks, David

 

David R Robison

Senior Systems Engineer

O. +1 512 247 3700

M. +1 757 286 0022

david.robison@psgglobal.net

www.psgglobal.net

cid:image003.png@01D19182.F24CA3E0

Prometheus Security Group Global, Inc.

3019 Alvin Devane Boulevard

Building 4, Suite 450

Austin, TX 78741

cid:image003.png@01D19182.F24CA3E0

 


_______________________________________________
undertow-dev mailing list
undertow-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/undertow-dev