2012-03-23 2 views
1

는이 게시물을노새 - 노새 (서버 리스너를) 시작하는 코드를 실행하는 방법을

MULE lifecycle - how to hook into startup process

을 읽고 있었다 그러나 나는 노새-config.xml 파일에서 XML을 넣어하는 방법을하지 않습니다. 나는 인바운드 엔드 포인트도 아웃 바운드 엔드 포인트도 없다. 수업을 시작하고 멈추고 코드를 실행해야합니다. 이것에 대한 노새 XML은 무엇입니까? 나는 이것의 어떤 예를 찾을 수 없다.

덕분에, 딘

답변

5

이 시도 :

<?xml version="1.0" encoding="UTF-8"?> 
<mule xmlns="http://www.mulesoft.org/schema/mule/core" 
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
     xmlns:spring="http://www.springframework.org/schema/beans" 
     xsi:schemaLocation=" 
       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd 
       http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/3.2/mule.xsd"> 
     <spring:beans> 
      <spring:bean id="initializer" class="org.myclass.that.implements.muleContextNotificationListener.MuleContextNotification"/> 
     </spring:beans> 

     <notifications> 
      <notification event="CONTEXT"/> 
      <notification-listener ref="initializer"/> 
     </notifications> 

    </mule> 

(this에 영감)

관련 문제