78.11. Spring을 사용하여 대상 및 컨duit 구성


78.11.1. 네임스페이스

Camel 전송 끝점을 구성하는 데 사용되는 요소는 네임스페이스 http://cxf.apache.org/transports/camel 에 정의되어 있습니다. 일반적으로 prefix comel을 사용합니다. Camel 전송 구성 요소를 사용하려면 아래에 표시된 행을 엔드포인트 구성 파일의Beans 요소에 추가해야 합니다. 또한 구성 요소의 네임스페이스를 xsi:schemaLocation 속성에 추가해야 합니다.

구성 네임스페이스 추가

<beans ...
       xmlns:camel="http://cxf.apache.org/transports/camel
       ...
       xsi:schemaLocation="...
                           http://cxf.apache.org/transports/camel
                           http://cxf.apache.org/transports/camel.xsd
                          ...>
Copy to Clipboard Toggle word wrap

78.11.2. 대상 요소

camel:destination 요소와 해당 하위 항목을 사용하여 Camel 전송 서버 엔드포인트를 구성합니다. camel:destination 요소는 엔드포인트에 해당하는 WSDL 포트 요소를 지정하는 단일 속성인 name 을 사용합니다. name 특성의 값은 폼 portQName'.camel-destination'을 사용합니다. 아래 예는 끝점의 대상 네임스페이스가 http://widgets.widgetvendor.net 인 경우 WSDL fragment < port binding="widgetSOAPBinding" name="widgetSOAPPort" >에 의해 지정된 엔드포인트에 대한 구성을 추가하는 데 사용되는 camel:destination 요소를 보여줍니다.

Camel:destination 요소

...
  <camel:destination name="{http://widgets/widgetvendor.net}widgetSOAPPort.http-destination>
    <camelContext id="context" xmlns="http://activemq.apache.org/camel/schema/spring">
         <route>
           <from uri="direct:EndpointC" />
           <to uri="direct:EndpointD" />
         </route>
     </camelContext>
  </camel:destination>

  <!-- new added feature since Camel 2.11.x
  <camel:destination name="{http://widgets/widgetvendor.net}widgetSOAPPort.camel-destination" camelContextId="context" />

...
Copy to Clipboard Toggle word wrap

Spring의 camel:destination 요소에는 구성 정보를 지정하는 여러 하위 요소가 있습니다. 아래에 설명되어 있습니다.

요소

설명

camel-spring:camelContext

camel 목적지에서 camel 컨텍스트를 지정할 수 있습니다.

camel:camelContextRef

camel 대상에 삽입하려는 camel 컨텍스트 ID

78.11.3. conduit 요소

camel:conduit 요소 및 해당 하위 항목을 사용하여 Camel 전송 클라이언트를 구성합니다. camel:conduit 요소는 엔드포인트에 해당하는 WSDL 포트 요소를 지정하는 단일 속성인 name 을 사용합니다. name 특성의 값은 폼 portQName'.camel-conduit'을 사용합니다. 예를 들어 아래 코드는 끝점의 대상 네임스페이스가 http://widgets.widgetvendor.net 인 경우 WSDL fragment < port binding="widgetSOAPBinding" name="widgetSOAPPort" >에 의해 지정된 엔드포인트에 대한 구성을 추가하는 데 사용되는 camel:conduit 요소를 보여줍니다.

HTTP-conf:conduit 요소

...
  <camelContext id="conduit_context" xmlns="http://activemq.apache.org/camel/schema/spring">
       <route>
           <from uri="direct:EndpointA" />
           <to uri="direct:EndpointB" />
       </route>
   </camelContext>

  <camel:conduit name="{http://widgets/widgetvendor.net}widgetSOAPPort.camel-conduit">
     <camel:camelContextRef>conduit_context</camel:camelContextRef>
  </camel:conduit>

  <!-- new added feature since Camel 2.11.x
  <camel:conduit name="{http://widgets/widgetvendor.net}widgetSOAPPort.camel-conduit" camelContextId="conduit_context" />


  <camel:conduit name="*.camel-conduit">
  <!-- you can also using the wild card to specify the camel-conduit that you want to configure -->
    ...
  </camel:conduit>
...
Copy to Clipboard Toggle word wrap

camel:conduit 요소에는 구성 정보를 지정하는 여러 자식 요소가 있습니다. 아래에 설명되어 있습니다.

요소

설명

camel-spring:camelContext

camel conduit에서 camel 컨텍스트를 지정할 수 있습니다.

camel:camelContextRef

camel conduit에 삽입하려는 camel 컨텍스트 ID

맨 위로 이동
Red Hat logoGithubredditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다. 최신 업데이트를 확인하세요.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

Theme

© 2025 Red Hat