从 catch-exception-strategy 抛出自定义异常
Throw custom exception from catch-exception-strategy
是否可以从 catch-exception-strategy
或任何其他异常策略中抛出我们自己的自定义异常。
我试过如下:
<catch-exception-strategy doc:name="Catch Exception Strategy">
<scripting:component doc:name="throw-custom-exception">
<scripting:script engine="Groovy">
<![CDATA[throw new org.mycompany.mule.CustomException()]]>
</scripting:script>
</scripting:component>
</catch-exception-strategy>
但最终出现错误:
org.mule.exception.CatchMessagingExceptionStrategy: Failed to dispatch message to error queue after it failed to process
谁能解决这个问题?提前致谢。
尝试将
<scripting:component doc:name="throw-custom-exception">
<scripting:script engine="Groovy">
<![CDATA[throw new org.mycompany.mule.CustomException()]]>
</scripting:script>
</scripting:component>
在 catch-exception-strategy
之外尝试...
是否可以从 catch-exception-strategy
或任何其他异常策略中抛出我们自己的自定义异常。
我试过如下:
<catch-exception-strategy doc:name="Catch Exception Strategy">
<scripting:component doc:name="throw-custom-exception">
<scripting:script engine="Groovy">
<![CDATA[throw new org.mycompany.mule.CustomException()]]>
</scripting:script>
</scripting:component>
</catch-exception-strategy>
但最终出现错误:
org.mule.exception.CatchMessagingExceptionStrategy: Failed to dispatch message to error queue after it failed to process
谁能解决这个问题?提前致谢。
尝试将
<scripting:component doc:name="throw-custom-exception">
<scripting:script engine="Groovy">
<![CDATA[throw new org.mycompany.mule.CustomException()]]>
</scripting:script>
</scripting:component>
在 catch-exception-strategy
之外尝试...