262.11. 속성 구성 요소 사용 예


끝점 URI에서 속성 자리 표시자를 사용하는 경우 속성: 구성 요소를 사용하거나 URI에서 직접 자리 표시자를 정의할 수 있습니다.When using property placeholders in the endpoint URIs you can either use the properties: component or define the placeholders directly in the URI. 우리는 이전부터 시작하여 두 가지 경우의 예를 보여줍니다.

// properties
cool.end=mock:result

// route
from("direct:start").to("properties:{{cool.end}}");

자리 표시자를 끝점 uri의 일부로 사용할 수도 있습니다.

// properties
cool.foo=result

// route
from("direct:start").to("properties:mock:{{cool.foo}}");

위의 예에서 to 끝점은 mock:result 로 확인됩니다.

다음과 같이 서로 참조를 사용하여 속성을 지정할 수도 있습니다.You can also have properties with refer to each other such as:

// properties
cool.foo=result
cool.concat=mock:{{cool.foo}}

// route
from("direct:start").to("properties:mock:{{cool.concat}}");

cool.concat 이 다른 속성을 참조하는 방법을 확인합니다.

properties: 구성 요소는 또한 locations 옵션을 사용하여 지정된 URI의 위치를 재정의하고 제공할 수 있습니다.

   from("direct:start").to("properties:bar.end?locations=com/mycompany/bar.properties");
Red Hat logoGithubredditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

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

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

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

Red Hat 소개

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

Theme

© 2026 Red Hat
맨 위로 이동