-
-
Notifications
You must be signed in to change notification settings - Fork 15.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HttpObjectAggregator could possibly leak in some conditions #5631
Comments
thanks for reporting @Spikhalskiy ! will look soon |
@Spikhalskiy - do you get any requests of type 100? also do you get any requests that exceed the maximum content length? are you able to reproduce the conditions that cause the leak? |
Yes, we have some % of requests of type "100 Continue".
No, we don't get TooLongFrameException in mainHandler.
No, I don't know which specific request or condition causing this leak. If it's hard to get into this problem with already provided info I would think about a way of collecting more data. |
BTW, more info, that could be related. We had a bug that we returned
in the mainHandler AFTER HttpObjectAggregator, which already does this. And looks like our clients failed after receiving this second "continue". After fixing this bug (removing this code from mainHandler) I didn't see leaks anymore, so it looks like something possibly related, or just by chance and I will see leak soon (this bug fixed just yesterday). On the same time, I don't get how it could be related because we sent this second continue in mainHandler, which have release() inside channelRead and we should see this release in advanced logs, but we don't. So, it shouldn't be that cases when we send this second continue. Just a stream of thoughts, that probably could be useful for you. |
The |
@Scottmitch yep, I already got it and bug with double continue fixed now in our server. Thanks for your work, waiting. |
Closed by #5676 |
Hi,
I am getting messages about buffer leaks in netty server very rarely, like once in 4-6 hours. And it looks like from advanced logging info that HttpObjectAggregator could not release buffer sometimes. My assumption - it could be related to closing idle connection while HttpObjectAggregator has something cached inside and HttpObjectAggregator doesn't release it correctly.
This is how my pipeline looks like:
mainHandler has
This is how cleaned up version of log looks like:
Full advanced logs: log1.txt log2.txt.
If this info would not be enough for troubleshooting I would try to write a handler that will analyse/log this situation more deeply when I get a chance.
Or, please, let me know if it looks like a mistake in user code, but for me it doesn't.
Netty version 4.0.38
The text was updated successfully, but these errors were encountered: