On Mon, 19 Dec 2005, Mark Womack wrote:

|  - prerender the message before the lock?

I'd say that this is a rather obvious performance improvement, and will 
IIUC also alleviate the deadlock-situations, since any objects that might 
cause deadlock by being locked as a side effect of rendering would be 
locked without any other locks held, preserving the linear lock-order.

Also, I think I saw that NDC uses HashTable keyed on Thread for its 
operation, which I find super-bad if I understand the usage correctly. 
What about ThreadLocal, in which case the NDC.remove() invocation on 
thread exit wouldn't be needed either?! ThreadLocal is "since 1.2", and 
since 1.4 and recent it is much faster than contended synchs around a Map.
  .. or at least use ConcurrentMap? But ThreadLocal is rather obvious 
here, I believe? Am I missing something? I could do such a patch..

Regards,
Endre.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to