2015-05-31 3 views
2

У меня есть основной поток мул:Mule - Восстанавливать соединение с основным потоком

HTTP =>SOAP =>JAVA CLASS

<mule xmlns:cxf="http://www.mulesoft.org/schema/mule/cxf" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" 
    xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.6.1" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd 
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd 
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd 
http://www.mulesoft.org/schema/mule/cxf http://www.mulesoft.org/schema/mule/cxf/current/mule-cxf.xsd"> 
    <http:listener-config name="HTTP_Listener_Configuration" host="0.0.0.0" port="8081" doc:name="HTTP Listener Configuration"/> 
    <flow name="test_dynamicsFlow"> 
     <http:listener config-ref="HTTP_Listener_Configuration" path="/" doc:name="HTTP"/> 
     <cxf:jaxws-service doc:name="CXF"/> 
     <component doc:name="Java"/> 
    </flow> 
</mule> 

Я хотел бы сделать повтор подключение к SOAP с таймаут, но я не знаю, возможно ли это.

Я искал ошибки разъемов обработки:

enter image description here

Должен ли я использовать эти разъемы, чтобы сделать это или как я могу это осуществить?

ответ

2

Вам необходимо обернуть свой HTTP-вызов областью until-successful.

Пример:

<until-successful objectStore-ref="objectStore" maxRetries="5" secondsBetweenRetries="60" > 
    <http:request config-ref="HTTP_Request_Configuration" path="submit" method="POST" /> 
</until-successful> 

Ссылка: https://developer.mulesoft.com/docs/display/current/Until+Successful+Scope

+0

С помощью этого решения можно возвращать сообщение? – user1911

+1

В синхронном режиме: да. –

+0

Спасибо, Дэвид. Да, у меня есть этот параметр, но я хотел бы вернуть персонализированное XML-сообщение. Мне нужно создать новый класс Java? Я думаю, что мне это нужно слишком: 'deadLetterQueue-ref' – user1911

Смежные вопросы