2013-06-03 65 views
1

我正嘗試使用持久隊列存儲從意外故障中恢復。我的騾子版本是3.3.1Mule永久存儲

我從隊列中拾取消息並輸入「until success」循環。如果騾因爲某種原因停下來,我希望這個信息持久。

這裏是我的相關代碼

<spring:bean id="outboundStore" class="org.mule.util.store.QueuePersistenceObjectStore" /> 

<until-successful objectStore-ref="outboundStore" 

我沒有看到.mule目錄的消息。我究竟做錯了什麼?

對不起,如果問題不清楚。根據要求

增加流量:

<flow name="InitialFlow" processingStrategy="synchronous"> 
    <inbound-endpoint ref="firstQueue"/> 
    <until-successful objectStore-ref="outboundStore" maxRetries="6" secondsBetweenRetries="5" deadLetterQueue-ref="secondQueue" failureExpression="groovy:message.getInvocationProperty('soapResponse') == 'BAD'"> 
     <flow-ref name="somSubFlow" /> 
    </until-successful> 
</flow> 

<sub-flow name="someSubFlow"> 
<http:outbound-endpoint ref="someEndpoint" exchange-pattern="request-response" method="GET" /> 
</sub-flow> 

請不要讓我知道如果你需要更多的信息。

+0

請完整提供流程配置。這可能有助於解決這個問題。 – user1760178

回答

2

使用與您非常相似的配置,我完全可以看到郵件在.mule/queuestore/queuestore目錄中寫入交付。

我能想到的唯一一個問題是這個表達式groovy:message.getInvocationProperty('soapResponse') == 'BAD'會與處理混淆。

此表達式正確嗎?爲什麼不使用MEL?

+0

Groovy表達式適用於重試,但我可以將其更改爲MEL。需要一些時間來找出MEL :)對不起...新手。感謝您的答覆。我明天早上會發布我的發現。 – Jeet

+0

出於好奇,是否有任何特定的設置要在vm:endpoint上完成?對不起,我沒有我的代碼,否則會提供。我認爲我的代碼是類似於 Jeet

+0

我刪除了失敗表達式,但沒有運氣。我想提一下,我從STS內部啓動Mule Server。這有什麼用嗎? – Jeet