제 요구 사항은 몇 분마다 데이터베이스를 폴링하고 SQL을 얻는 것입니다. 따라서 내 코드는요소 'simple'로 시작하는 잘못된 콘텐츠가 발견되었습니다. 낙타 문제
<camel:route>
<camel:from uri="timer:dataRetrieve?period=5s"/>
<camel:to uri="sql:select output_obj,create_dt,destination_type from dbo.gcas_events_test where process_sw = 'N' order by create_dt desc" />
</camel:route>
내 데이터 세트에서 3 개의 필드가 필요합니다. 나는 destination_type = 'SEC'인지보고 싶다. 그러면 다른 경로로 가야한다.
그래서 생각해 냈습니다.
<camel:route>
<camel:from uri="timer:dataRetrieve?period=5s"/>
<camel:to uri="sql:select output_obj,create_dt,destination_type from dbo.gcas_events_test where process_sw = 'N' order by create_dt desc" />
<camel:choice>
<camel:when>
<simple>${body.destination_type}='SEC'</simple>
<camel:to uri="foo" />
</camel:when>
</camel:choice>
</camel:route>
간단한 태그에 오류가 발생합니다. ognl과 비슷한 문제. 여기서 내가 뭘 잘못하고 있니? ${body.destination_type}='SEC'
도 사용할 수 있습니까? (데이터 집합에 해당 값이 있다고 가정).
을 사용할 수 있습니다. 고마워. – Krishna