The fault is generated by the service provider. If you use the BC Soap as consumer, the fault is generated by an other service provided by a component.
This problem is known (bug #310494) and it is fixed in CDK 4.0.2.
As the BC Soap 3.1.2 uses the CDK 4.0.4, I think that you use the BC Soap as consumer. What component are you using as service provider ?
In fact, when my EJB throws an exception, this exception have a message that I would like to find in the "faultstring" of the JBI fault message.
But in the "callEJB" method in the ServiceManager class, the EJB's exception is in the cause of the exception.
Finally, I "lose" my original message that could be a code like "T_001" for technical error n° 001. Without this message, the composite application doesn't know what to do with this error.
That's explain my code.
The other error is really a part of this proposition...
Sorry I don't understand your answer.
If I write my question in an other way, my need is :
When an EJB throws an exception with a message in it. If my application consumes through the BC SOAP witch consume through the bC EJB my EJB, how do I retrieved my message ?
I precise that I don't want my EJB to throw a Petals' Exception. The ESB must not be intrusive in my Application Server.
The application might be a VB ou Delphi or whatever, not necessarily java application
I have located the ServiceManager. I agree with you about exception management.
Please create an issue in the PEtALS forge about this exception problem.
Moreover, I think that you can enter an other issue. Reading the ServiceManager source code, if a exception occurs during the first EJB invocation, an other call is made when catching InvocationTargetException. The application server connection loss must be improved.