,當我的API試圖連接到數據庫中,我堅持了以下錯誤:騾:java.util.concurrent.TimeoutException:超時超過
消息:Error發送HTTP請求。消息有效載荷的類型爲:字符串 類型:org.mule.api.MessagingException 代碼:MULE_ERROR - 2 的JavaDoc:http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/MessagingException.html
異常堆棧是: 1.超時超出(java.util.concurrent中.TimeoutException) com.ning.http.client.providers.grizzly.GrizzlyAsyncHttpProvider:426(null) 2.發送HTTP請求時出錯。消息有效載荷的類型爲:字符串(org.mule.api.MessagingException) org.mule.module.http.internal.request.DefaultHttpRequester:287(http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/MessagingException.html)
根異常堆棧跟蹤: 的java。 util.concurrent.TimeoutException:超時在com.ning.http.client.providers.grizzly.GrizzlyAsyncHttpProvider.timeout(GrizzlyAsyncHttpProvider.java:426) 超過 在com.ning.http.client.providers.grizzly.GrizzlyAsyncHttpProvider $ 3.onTimeout (GrizzlyAsyncHttpProvider.java:274) at org.glassfish.grizzly.utils.IdleTimeoutFilter $ DefaultWorker.doWork(IdleTimeoutFilter.java:398) at org.glassfish.griz zly.utils.IdleTimeoutFilter $ DefaultWorker.doWork(IdleTimeoutFilter.java:377) 在org.glassfish.grizzly.utils.DelayedExecutor $ DelayedRunnable.run(DelayedExecutor.java:158) 在java.util.concurrent.ThreadPoolExecutor.runWorker( ThreadPoolExecutor.java:1142) 在java.util.concurrent.ThreadPoolExecutor中的$ Worker.run(ThreadPoolExecutor.java:617) 在java.lang.Thread.run(Thread.java:745)
我的API是試圖連接到數據庫如下:
<flow name="system-api-config" >
<set-property propertyName="Content-Type" value="application/json" doc:name="Set Content Type"/>
<json:json-to-object-transformer returnClass="java.lang.Object" doc:name="JSON to Object"/>
<!-- <set-variable variableName="agreementLinePayload" value="#[new java.util.ArrayList()]" doc:name="Set Entries"/> -->
<set-variable variableName="agPayload" value="#[new java.util.HashMap()]" doc:name="Set Entries"/>
<set-variable variableName="agLnID" value="#[payload.agLnID]" "/>
<set-variable variableName="exe" value="#[payload.exe]" "/>
<logger message="Extended Price :#[flowVars.extendedPrice]" level="INFO" doc:name="Logger"/>
<expression-component doc:name="Expression"><![CDATA[
flowVars.agreementLinePayload.add(payload.agLnID);
flowVars.agreementLinePayload.add(payload.exe);
]]>
</expression-component>
<db:bulk-execute config-ref="Oracle_Configuration" doc:name="Database"><![CDATA[INSERT INTO HDR(ID,
someNUMBER,
START_DATE,
END_DATE,
O_NUMBER)
VALUES (SEQ.NEXTVAL,
NUM_SEQ.NEXTVAL,
TO_DATE('2017-02-17','YYYY-MM-DD HH24:MI:SS'),
TO_DATE('2018-02-17','YYYY-MM-DD HH24:MI:SS'),
#[payload.myField])
</db:bulk-execute>
...。
我試過切換連接超時& HTTP請求超時但無濟於事。當我進行數據庫調用時,它總會給出這個超時異常,請給點意見。