Hi, I'm implementing an HTTP server with netty 4.1.6.Final, and I would like to implement an access log. This is what I would like to do, considering that I'm trying to never call writeAndFlush but just write and flush is called only when a read complete event has been fired:
1. get the start time before the the message is decoded to an HttpRequest (before the HTTP codec) 2. get method, protocol, uri, x-forwarded-for and x-forwarded-proto headers immediately after the message has been decoded in a HTTP request 3. get response status and content length when I write the HTTP response 4. get the response time when I flush The problem I'm facing is that I cannot keep trace of all those informations as channel attributes cause a read operation could happen before the flush is called. Even if I try to keep those information grouped by a messageId set at the very first read, I cannot know, when I flush, to which original message I'm responding. Does it makes sense? Am I approaching the problem in a wrong way? Thanks for helping. Regards, Denis Rossi -- You received this message because you are subscribed to the Google Groups "Netty discussions" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/netty/bd4b6427-7c24-4557-b589-f4381bfe2925%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
