Fuse 6 is no longer supported
As of February 2025, Red Hat Fuse 6 is no longer supported. If you are using Fuse 6, please upgrade to Red Hat build of Apache Camel.此内容没有您所选择的语言版本。
19.16. Indirect Service Invocation With Annotations
In the example below, annotations have been added to the bean called
Order
to manage invocation:
- Annotations @Named and @RequestScoped have been added.
- The
OrderService
property has a @Reference annotation. Because of this, its instance is not a reference to the actual service implementation. Instead, it is a SwitchYard Exchange proxy to that service implementation. By using @Reference injected service references, backend service implementations can be non-CDI Bean service implementations. - Implementing the create method invokes the
OrderService
reference (exchange proxy).