axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Manuel Mall <>
Subject Re: Axis client thread safety
Date Sun, 11 Jun 2006 03:12:53 GMT
On Sunday 11 June 2006 06:36, Cyrille Le Clerc wrote:
>    Hello Manuel,
>    My understanding is the Stub#createCall invokes methods on an
> instance of TypeMapping that is shared by the AxisEngine via the
> TypeMappingRegistry. Unfortunately, this TypeMappingImpl is not
> threadsafe.

I was afraid that would be the case. Curious how come I am (actually my 
customer) the first one to stumble across this. Axis has been around 
for quite some time and is used many production environments I thought.

>    Here is a a draft patch that should fix it waiting for an official
> patch. Note that I didn't succeed in reproducing the deadlock, I
> patched according to my understanding of the problem.
>    Moreover, I preferred to send you this draft/emergency patch
> before doing extensive testings. It works on my samples but I didn't
> look at the impact on performances (it should be limited ).

Your quick patch is much appreciated Cyrille. However, I looked at the 
source included in the jar file and a diff against the original didn't 
show any differences. Before asking my customer to test with this (I 
can't reproduce the problem on my systems either) I would like to make 
sure I can build myself what I provide to them.

BTW, I have reported the problem in Jira now:

>    Here is a draft patch to fix this issue. To use it, the easiest
> way is to unzip axis-1.4-threadSafetyPatch.jar under /WEB-INF/classes
> (classloader order).
> is the only modified class. Modifications:
> - use synchronized maps instead of plain HashMaps
> - synchronize internalRegister() method to ensure atomicity of access
> to maps in modification
> - synchronize access to "namespaces" variable in
> setSupportedEncodings to ensure atomicity of the clear-add sequence
>    Hope this helps,
>    Cyrille

Thanks again


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message