If the invocation of the business logic throws an exception that is mapped to a fault response, the exception is logged as error (AxisEngine.receive(MessageContext msgContext), see end of the method).
Logging an error usually indicates that something went wrong. From the perspective of the Axis2 framework, however, everything is perfectly OK. The business logic has thrown an exception, it is returned to the invoker as a fault, so where's the error? (Compare in contrast the better handling in AbstractMessageReceiver.receive(final MessageContext messageCtx). Here the exception is only logged as error if it happens to be an "in only" message exchange, i.e. when the client cannot be notified about the exception.)
We have a system where exceptions are thrown by the business logic quite frequently (it's a "customer not registered for this service" situation). While you could argue that we had better defined a WSDL in which this situation is mapped to some "normal" result instead of a fault, our definition is perfectly within the SOAP specs. The excessive error messages in the log, however, result in unnecessary alerts in monitoring. We'll probably have to set the log level for AxisKernel to FATAL, although we do not like to do this.
|Field||Original Value||New Value|
|Assignee||Andreas Veithen [ veithen ]|
|Status||Open [ 1 ]||Resolved [ 5 ]|
|Fix Version/s||1.6 [ 12313622 ]|
|Fix Version/s||1.5.3 [ 12315367 ]|
|Resolution||Duplicate [ 3 ]|