291.5. 샘플

60초마다 이벤트를 생성하는 경로를 설정하려면 다음을 수행합니다.

from("scheduler://foo?delay=60s").to("bean:myBean?method=someMethodName");

위의 경로는 이벤트를 생성한 다음 JNDI 또는 Spring과 같은 레지스트리에서 myBean 이라는 빈에서 someMethodName 메서드를 호출합니다.

그리고 Spring DSL의 경로:

<route>
  <from uri="scheduler://foo?delay=60s"/>
  <to uri="bean:myBean?method=someMethodName"/>
</route>