錯誤Invalid Session ID
在Mule上發生了與SugarCRM Connector(http://mulesoft.github.io/sugarcrm-connector/)一起使用SOAP的應用程序。Mule:無效的會話ID
但這個錯誤發生在這樣的場景:
- 應用程序啓動和處理所有的民意調查(數據庫查詢)
- SOAP工作正常
- 應用程序保持等待一個新的更新/插入
- 後(24小時,pe)發生新的更新/插入
- 流程在應用程序中處理
- 但是,會發生以下錯誤(repreat永遠):
編輯:
2016年3月24日12:31:30470 [池-106-螺紋-1] ERROR org.mule.retry。 notifiers.ConnectNotifier - 無法連接/重新連接 :工作描述符。根異常是:無效的 會話ID。類型:class org.apache.cxf.binding.soap.SoapFault 2016-03-24 12:31:30,471 [pool-106-thread-1]錯誤 org.mule.exception.DefaultMessagingExceptionStrategy - ***** ************************************************** *************************消息:無法調用getEntryList。消息有效負載 的類型爲:GetEntryListRequest代碼: MULE_ERROR-29999 ----------------------------------- ---------------------------------------------異常堆棧是: 1.無效的會話ID(org.apache.cxf.binding.soap.SoapFault)org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor:84 (null) 2.無效的會話ID(javax.xml.ws。 soap.SOAPFaultException)org.apache.cxf.jaxws.JaxWsClientProxy:158 (http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/xml/ws/soap/SOAPFaultException.html) 3.無法調用getEntryList。消息有效負載的類型爲:GetEntryListRequest(org.mule.api.MessagingException)
org.mule.devkit.processor.DevkitBasedMessageProcessor:133 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/MessagingException.html) ---------------- -------------------------------------------------- --------------根異常堆棧跟蹤:org.apache.cxf.binding.soap.SoapFault: 無效的會話ID org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor .unmarshalFault(Soap11FaultInInterceptor.java:84) 在 org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessage(Soap11FaultInInterceptor.java:51) 在 org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor .handleMessage(Soap11FaultInInterceptor.jav一:40) + 3以上(組調試級記錄或一切 '-Dmule.verbose.exceptions =真')
2016年3月24日12:31:40471 [池-106-螺紋-1]錯誤 org.mule.retry.notifiers.ConnectNotifier - 未能連接/重新連接 :工作描述符。根異常是:無效的 會話ID。類型:class org.apache.cxf.binding.soap.SoapFault 2016-03-24 12:31:40,472 [pool-106-thread-1]錯誤 org.mule.exception。DefaultMessagingException策略 - *********************************************** *********************************消息:無法調用getEntryList。消息有效負載 的類型爲:GetEntryListRequest代碼: MULE_ERROR-29999 ----------------------------------- ---------------------------------------------異常堆棧是: 1.無效的會話ID(org.apache.cxf.binding.soap.SoapFault)org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor:84 (null) 2.無效的會話ID(javax.xml.ws。 soap.SOAPFaultException)org.apache.cxf.jaxws.JaxWsClientProxy:158 (http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/xml/ws/soap/SOAPFaultException.html) 3.無法調用getEntryList。消息有效負載的類型爲:GetEntryListRequest(org.mule.api.MessagingException)
org.mule.devkit.processor.DevkitBasedMessageProcessor:133 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/MessagingException.html) ---------------- -------------------------------------------------- --------------根異常堆棧跟蹤:org.apache.cxf.binding.soap.SoapFault: 無效的會話ID org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor .unmarshalFault(Soap11FaultInInterceptor.java:84) 在 org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessage(Soap11FaultInInterceptor.java:51) 在 org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor .handleMessage(Soap11FaultInInterceptor.jav一:40) + 3以上(組調試級記錄或一切「-Dmule.verbose.exceptions =真」)
我配置重新連接符合下面的圖像,但不錯誤繼續。
編輯:
XML配置(簡體)
<db:oracle-config name="Oracle_Configuration" host="${db.host}" port="${db.port}" instance="${db.instance}" user="${db.user}" password="${db.password}" doc:name="Oracle Configuration">
<db:pooling-profile/>
</db:oracle-config>
<sugar:config name="Sugar__Configuration" username="${crm.ws.user}" password="${crm.ws.password}" endpoint="${crm.ws.endpoint}" doc:name="Sugar: Configuration">
<sugar:connection-pooling-profile initialisationPolicy="INITIALISE_ONE" exhaustedAction="WHEN_EXHAUSTED_GROW"/>
<reconnect-forever frequency="60000"/>
</sugar:config>
<flow name="produto-precoFlow" processingStrategy="synchronous">
<poll doc:name="Poll" doc:description="Produto">
<fixed-frequency-scheduler frequency="10000"/>
<watermark variable="carimboTempo" default-expression="2016-02-24 00:00:00" selector="MAX" selector-expression="#[message.payload.datalt]"/>
<db:select config-ref="Oracle_Configuration" doc:name="Database">
<db:parameterized-query><![CDATA[SELECT * FROM PRODUTO WHERE TO_CHAR(DATALT, 'yyyy-mm-dd hh24:mi:ss') > #[flowVars.carimboTempo]]]></db:parameterized-query>
</db:select>
</poll>
<foreach doc:name="For Each">
<enricher target="#[payload.produtoPrecoSugar]" doc:name="Message Enricher Produto">
<flow-ref name="produto-precoSub_FlowProduto" doc:name="produto-precoSub_FlowProduto"/>
</enricher>
// [...] mode code here (original)
<scripting:component doc:name="Groovy Inserir/Alterar">
<scripting:script engine="Groovy"><![CDATA[import org.mule.modules.sugarcrm.request.SetEntryRequest;
import com.sugarcrm.sugarcrm.NameValue;
req = new SetEntryRequest();
req.setModuleName("AOS_Products");
nameValues = [];
for (e in message.payload) {
nameValue = new NameValue();
nameValue.setName(e.key);
nameValue.setValue(e.value.toString());
nameValues.add(nameValue);
}
req.setNameValueList(nameValues);
return req;]]></scripting:script>
</scripting:component>
<sugar:set-entry config-ref="Sugar__Configuration" doc:name="Sugar Inserir/Alterar"/>
</foreach>
</flow>
<sub-flow name="produto-precoSub_FlowProduto">
<scripting:component doc:name="Groovy Id Produto">
<scripting:script engine="Groovy"><![CDATA[import org.mule.modules.sugarcrm.request.GetEntryListRequest;
req = new GetEntryListRequest();
req.setModuleName("AOS_Products");
whereQuery = "aos_products.deleted = 0";
for (e in message.payload) {
if (e.key == "sapiens_codtpr_c" || e.key == "sapiens_datini_c" || e.key == "sapiens_codser_c") {
whereQuery = whereQuery + " and " + e.key + " = '" + e.value.toString() + "'";
} else if (e.key == "sapiens_codemp_c" || e.key == "sapiens_qtdmax_c") {
whereQuery = whereQuery + " and " + e.key + " = " + e.value.toString();
}
}
req.setQuery(whereQuery);
req.setSelectFields(["id"]);
req.setDeleted(0);
return req;
]]></scripting:script>
</scripting:component>
<sugar:get-entry-list config-ref="Sugar__Configuration" doc:name="Sugar Id Produto e Preço"/>
</sub-flow>
什麼可以ocurring?有沒有可以解決這個問題的表單?
會話ID是否可以過期?你是如何得到它的第一個地方? –
服務器上的會話可能已過期(超時),是的。但在這種情況下,騾應該重新連接,對(重新連接策略)?第一次,連接是由Mule服務器在啓動/首次請求時通過Sugar連接參數完成的。上面編輯以包含XML配置。 – Muka