问题
I'm trying to run the program from the beginner tutorial on mulesoft, with the spell check service. I don't know what seems to be going wrong but it seems to time out, I get a mule_error--2. I think the spell check cloud hub service is not running...
This is the result:
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Started app 'spellchecker' +
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
INFO 2013-07-25 15:41:33,413 [[spellchecker].connector.file.mule.default.receiver.01] org.mule.transport.file.FileMessageReceiver: Lock obtained on file: C:\Users\mahmadzada\Desktop\mule\MuleStudio\examples\SpellChecker\InXML\spellcheck.xml
INFO 2013-07-25 15:41:33,463 [[spellchecker].SpellCheckerFlow1.stage1.02] org.mule.transport.service.DefaultTransportServiceDescriptor: Loading default outbound transformer: org.mule.transport.http.transformers.ObjectToHttpClientMethodRequest
INFO 2013-07-25 15:41:33,466 [[spellchecker].SpellCheckerFlow1.stage1.02] org.mule.transport.service.DefaultTransportServiceDescriptor: Loading default response transformer: org.mule.transport.http.transformers.MuleMessageToHttpResponse
INFO 2013-07-25 15:41:33,475 [[spellchecker].SpellCheckerFlow1.stage1.02] org.mule.transport.service.DefaultTransportServiceDescriptor: Loading default outbound transformer: org.mule.transport.http.transformers.ObjectToHttpClientMethodRequest
INFO 2013-07-25 15:41:33,476 [[spellchecker].SpellCheckerFlow1.stage1.02] org.mule.lifecycle.AbstractLifecycleManager: Initialising: 'connector.http.mule.default.dispatcher.212447412'. Object is: HttpClientMessageDispatcher
INFO 2013-07-25 15:41:33,478 [[spellchecker].SpellCheckerFlow1.stage1.02] org.mule.lifecycle.AbstractLifecycleManager: Starting: 'connector.http.mule.default.dispatcher.212447412'. Object is: HttpClientMessageDispatcher
INFO 2013-07-25 15:41:33,494 [[spellchecker].SpellCheckerFlow1.stage1.02] org.mule.transport.http.transformers.ObjectToHttpClientMethodRequest: Content-Type not set on outgoing request, defaulting to: text/plain
ERROR 2013-07-25 15:41:44,065 [[spellchecker].SpellCheckerFlow1.stage1.02] org.mule.exception.DefaultMessagingExceptionStrategy:
********************************************************************************
Message : Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://spellcheck-service.cloudhub.io/spellcheck:80, connector=HttpConnector
{
name=connector.http.mule.default
lifecycle=start
this=ece5b80
numberOfConcurrentTransactedReceivers=4
createMultipleTransactedReceivers=true
connected=true
supportedProtocols=[http]
serviceOverrides=<none>
}
, name='endpoint.http.spellcheck.service.cloudhub.io.spellcheck.80', mep=REQUEST_RESPONSE, properties={http.method=POST}, transactionConfig=Transaction{factory=null, action=INDIFFERENT, timeout=0}, deleteUnacceptedMessages=false, initialState=started, responseTimeout=10000, endpointEncoding=UTF-8, disableTransportTransformer=false}. Message payload is of type: PostMethod
Code : MULE_ERROR--2
--------------------------------------------------------------------------------
Exception stack is:
1. Read timed out (java.net.SocketTimeoutException)
java.net.SocketInputStream:-2 (null)
2. Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://spellcheck-service.cloudhub.io/spellcheck:80, connector=HttpConnector
{
name=connector.http.mule.default
lifecycle=start
this=ece5b80
numberOfConcurrentTransactedReceivers=4
createMultipleTransactedReceivers=true
connected=true
supportedProtocols=[http]
serviceOverrides=<none>
}
, name='endpoint.http.spellcheck.service.cloudhub.io.spellcheck.80', mep=REQUEST_RESPONSE, properties={http.method=POST}, transactionConfig=Transaction{factory=null, action=INDIFFERENT, timeout=0}, deleteUnacceptedMessages=false, initialState=started, responseTimeout=10000, endpointEncoding=UTF-8, disableTransportTransformer=false}. Message payload is of type: PostMethod (org.mule.api.transport.DispatchException)
org.mule.transport.http.HttpClientMessageDispatcher:155 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/transport/DispatchException.html)
--------------------------------------------------------------------------------
Root Exception stack trace:
java.net.SocketTimeoutException: Read timed out
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(Unknown Source)
at java.net.SocketInputStream.read(Unknown Source)
+ 3 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything)
********************************************************************************
回答1:
The service was in limbo.
MuleSoft has applied CPR to it and you should be good now.
来源:https://stackoverflow.com/questions/17867363/spellcheck-service-cloudhub-io-spellcheck-times-out-from-the-mulesoft-mule-begin