Wanting to return the message from a custom Exception as a SOAP Fault string
I have wired the bean ...
Code:
<bean id="endpointExceptionResolver" class="org.springframework.ws.soap.endpoint.SoapFaultMappingExceptionResolver">
<property name="defaultFault">
<value>RECEIVER,Server error</value>
</property>
<property name="exceptionMappings">
<props>
<prop key="org.springframework.oxm.UnmarshallingException">SENDER,Invalid request</prop>
<prop key="org.springframework.oxm.ValidationFailureException">SENDER,Invalid request</prop>
<prop key="com.company.exception.DateNotFoundException">RECEIVER,Date not Found in Launch Calendar</prop>
<prop key="com.company.exception.LockdownException">RECEIVER,Site is in lockdown.</prop>
</props>
</property>
</bean>
My goal is to get the message inside my custom exception objects and send that message back as the faultstring. How can I do this?