You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2021/11/18 10:00:01 UTC
[camel-examples] 04/05: Fixed example
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-examples.git
commit c31a82b295186b7d83e63f916e4a72d5f29fea3e
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Thu Nov 18 10:59:28 2021 +0100
Fixed example
---
.../src/main/java/org/apache/camel/example/cdi/xml/Application.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/examples/cdi-xml/src/main/java/org/apache/camel/example/cdi/xml/Application.java b/examples/cdi-xml/src/main/java/org/apache/camel/example/cdi/xml/Application.java
index 5a741cc..19ea6d4 100644
--- a/examples/cdi-xml/src/main/java/org/apache/camel/example/cdi/xml/Application.java
+++ b/examples/cdi-xml/src/main/java/org/apache/camel/example/cdi/xml/Application.java
@@ -25,6 +25,7 @@ import javax.inject.Named;
import org.apache.camel.Body;
import org.apache.camel.CamelException;
+import org.apache.camel.Exchange;
import org.apache.camel.Handler;
import org.apache.camel.Processor;
import org.apache.camel.cdi.ImportResource;
@@ -50,7 +51,7 @@ public class Application {
@Named
@Produces
Processor tracer = exchange -> exchange.getIn()
- .setHeader("location", simple("${exchangeProperty.CamelFailureRouteId}"));
+ .setHeader("location", exchange.getProperty(Exchange.FAILURE_ROUTE_ID));
void login(@Observes @Initialized(ApplicationScoped.class) Object event) {
System.out.println(