On 05/22/2012 10:07 AM, Klaus Darilion wrote:
In my opinion it would be cool if core has a feature to log every received and every sent message. The logging should include timestamp+proto+sourceIP:port+receivedIP:port for received messages and timestamp+proto+sourceIP:port+destinationIP:port for sent messages. For TLS of course it should log the encrypted message.
Configuration should be done with a core parameter "message_log=0-4", similiar to memlog.
IIRC there were again issues with siptrace not logging all messages and for example on a load balancer I do not want to use a DB just for logging.
Hello,
Siptrace can log all messages if used in onsend_route with the patch Anca provided (will be merged into the master after 3.3 branching). ATM, onsend is called only for messages and not replies but the patch addresses this. You can use siptrace to log the messages to a separate K instance, and there use any DB backend to store the messages.
Regarding logging, I think you can get all these parameters from route(), reply_route() (for incoming) and onsend_route() (for outgoing) and using xlog() statements.
Cheers, Marius