[Design of AOP on JBoss (Aspects/JBoss)] - Re: Thread-Safety problems GeneratedClassAdvisor
by flavia.rainone@jboss.com
Jason, thanks for the input. Both issues you have raised are already fixed in the trunk. :)
Unfortunately, none of them issues are the cause of bug JBAOP-480.
What is happening is that a thread is trying to generate a joinpoint class for a joinpoint whose info interceptor chain is null. Here is how this happens: in an if-statement, thread 1 checks that the info object of joinpoint A contains a non-empty interceptor chain; thread 1 is preempted by thread2; thread2 removes the last interceptor bound to joinpoint A, recreating a new info field for joinnpoint A with a null interceptor chain; thread1 resumes, generating code to intercept joinpoint A, without being aware that its info contains now a null interceptor chain.
To avoid that, all I should do is to synchronize the thread on the joinpoint itself. This, added to some synchronization I have put on JoinPointInfo (I haven't commited this part since, alone, it is not a solution to anything), would do the trick.
But the problem is which object should be picked for the synchronization on the joinpoint? If we generated only one joinpoint info during all the JBoss AOP execution, this info would be a no-brain choice. However, since a new info is created at every rebuildInterceptors execution, we have no such object.
The interesting part is that I was already going to propose a change in this structure before Jason reported this concurrency isse :). My change would allow us to solve this problem easily, as well as bug JBAOP-380.
Kabir, I'll let you know a more detailed picture of this new approach tomorrow morning.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099117#4099117
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099117
17 years, 4 months
[Design of JBoss Web Services] - Re: Problems getting WS into ESB
by Kevin.Conner@jboss.com
"thomas.diesler(a)jboss.com" wrote : anonymous wrote :
| | I still don't know whether the SP2 release includes this fix or not, you owe me an answer on that one ;)
| |
|
| Yes it does.
|
Thank you :)
"thomas.diesler(a)jboss.com" wrote : #2 we use the AS4.2.1 binary relase
Yes, we use the binary.
"thomas.diesler(a)jboss.com" wrote : In both cases installing jbossws-2.0.1.SP2 is not trivial because the AS container integration has moved to Branch_4_2 after the AS4.2.1 release.
Which is the issue Trevor is finding. I am assuming that 'after the AS4.2.1 release' means 'AS4.2.2 and later', is this correct?
"thomas.diesler(a)jboss.com" wrote : Please show me exactly how you attempted to install jbossws-2.0.1.SP2 from that I can probably see how it should be done properly.
I believe Trevor is using your installation scripts to handle this aspect.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099113#4099113
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099113
17 years, 4 months