logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Smith <psm...@aconex.com>
Subject 1.2 & 1.3 serialization
Date Fri, 06 Apr 2007 04:44:43 GMT
Well, I'm quite confused about exactly why log4j1.2 events don't  
quite have all the info when read into a 1.3 runtime (specifically  
MDC).  I can only surmise that the reason is that in 1.2 the field is  
called 'mdcCopy' and is a Hashtable, and in 1.3 it's called  
'properties' and is a Map and so the default serialization read can't  
match  them up.

I'm no serialization expert, so I have no idea how to fix this.   
Anyone got any ideas?  I'm quite surprised given the changes between  
1.2 and 1.3 in LoggingEvent that it works at all.

One hack I can think of but might not work is to restore the private  
field called 'mdcCopy' and during serialization transport it to the  
properties object and release the referenence on mdcCopy... ?

Time to re-read up on Serialization Voodoo majik.

Paul

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org


Mime
View raw message