簡體   English   中英

為什么在部署以下mule流時,由於ObjectStoreException而遇到“輸入流有效負載無法分發”?

[英]Why do I encounter “inputstream payload cant be distributed” due to ObjectStoreException when deploying the following mule flow?

我的mule流日志中出現以下異常:

ERROR 12/09/13 22:33:18 (rg.mule.module.logging.DispatchingLogger:341 ) <org.mule.exception.DefaultMessagingExceptionStrategy>
********************************************************************************
Message               : InputStream payload can't be distributed in a cluster
Type                  : org.mule.api.store.ObjectStoreException
Code                  : MULE_ERROR--2
JavaDoc               : mulesoft.org/docs/site/current3/apidocs/org/mule/api/store/ObjectStoreException.html
********************************************************************************
Exception stack is:
1. InputStream payload can't be distributed in a cluster (org.mule.api.store.ObjectStoreException)
  com.mulesoft.mule.cluster.hazelcast.HazecastQueueObjectStoreAdapter:52 
********************************************************************************
Root Exception stack trace:
org.mule.api.store.ObjectStoreException: InputStream payload can't be distributed in a cluster
        at com.mulesoft.mule.cluster.hazelcast.HazecastQueueObjectStoreAdapter.validatePayloadType(HazecastQueueObjectStoreAdapter.java:52)
        at com.mulesoft.mule.cluster.hazelcast.HazecastQueueObjectStoreAdapter.store(HazecastQueueObjectStoreAdapter.java:34)....
********************************************************************************

我的騾子流是:

<flow name="hawkeye-mule-heartbeat-history-reapingFlow" doc:name="hawkeye-mule-heartbeat-history-reapingFlow">
    <poll frequency="${hb.historical.polling.interval}" doc:name="Poll">
        <http:outbound-endpoint exchange-pattern="request-response" host="${hb.rest.host}" port="${hb.rest.port}" 
            path="${hb.rest.baseURI}/history?expiry=${hb.historical.expiry}" method="DELETE" doc:name="HTTP" mimeType="application/json"/>
    </poll>
    <byte-array-to-string-transformer doc:name="Byte Array to String"/>
    <logger message="hawkeye.mule.heartbeat.history.reaping HTTP Request: ${hb.rest.protocol}://${hb.rest.host}:${hb.rest.port}${hb.rest.baseURI}/history?expiry=${hb.historical.expiry}" 
        level="DEBUG" category="heartbeatReaping" doc:name="HTTP Request logger"/>
    <logger message="hawkeye.mule.heartbeat.history.reaping reaped heartbeats" level="INFO" category="heartbeatReaping" doc:name="Log Heartbeat Reaper" />
</flow>

我正在記錄消息的有效負載和響應代碼,這就是目標,但刪除了這個以嘗試消除異常無濟於事。 這個mule流在本地運行而沒有問題在mule studio中,但是當它部署在我們的集群上時,我得到了上述異常。 騾子文檔不是很有幫助。 任何意見,將不勝感激。

拋出ObjectStoreException的原因是因為我需要通過向flow元素添加屬性processingStrategy =“synchronous”來明確告訴mule處理策略是同步的。

然而,目前還不清楚為什么我需要明確告訴mule這個流處理策略是同步的。 文件騾子提供讓我相信騾子選擇正確的策略,如果沒有提供。

發生這種情況是因為在群集模式下,Mule序列化消息有效負載並在流的消息源中跨群集共享它們。 在您的情況下,源是poll元素。

這說,失敗看起來像一個錯誤:這應該優雅地工作。 作為一種解決方法,你可以嘗試在輪詢器中串行化為byte[]嗎?

<poll frequency="${hb.historical.polling.interval}">
    <http:outbound-endpoint exchange-pattern="request-response" host="${hb.rest.host}" port="${hb.rest.port}" 
        path="${hb.rest.baseURI}/history?expiry=${hb.historical.expiry}"
        method="DELETE" mimeType="application/json">
       <response>
         <byte-array-to-string-transformer />
       </response>
    </http:outbound-endpoint>
</poll>

但是既然你正在使用EE,那么最好是聯系MuleSoft支持:它可能是一個已經修復過的bug。 他們會讓你知道,提供補丁等......

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM