serve icon indicating copy to clipboard operation
serve copied to clipboard

Show warning to increase `max_response_size` if `CorruptedFrameException`

Open msaroufim opened this issue 3 years ago • 2 comments

🚀 The feature

A few customers I've chatted with have been confused with a CorruptedFrameException error https://github.com/pytorch/serve/issues?q=CorruptedFrameException

The fix is to increase the max_response_size in config.properties so we should probably just print that in warnings

Motivation, pitch

See above

Alternatives

No response

Additional context

No response

msaroufim avatar Sep 22 '22 00:09 msaroufim

I'm a first time contributer and I wanted to take a crack at this. I wanted to check, could I add to this catch:

} catch (Throwable t) {
            // https://github.com/netty/netty/issues/2597
            if (t instanceof IOException) {
                throw new WorkerInitializationException("Failed to connect to worker.", t);
            }
            throw t;
        }

https://github.com/pytorch/serve/blob/master/frontend/server/src/main/java/org/pytorch/serve/wlm/WorkerThread.java line 365

and log (slf4j) the warning if t is a CorruptedFrameException instance to resolve this?

tanayg2 avatar Sep 22 '22 08:09 tanayg2

I think so? Might be worth running a quick check with a very tiny value of max response size to see if you can reliably trigger the warning

msaroufim avatar Sep 22 '22 16:09 msaroufim