You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/user-manual/modules/ROOT/pages/pojo-consuming.adoc
+37-19Lines changed: 37 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,18 +5,12 @@ annotation to mark a particular method of a bean as being a consumer
5
5
method. The value of the annotation defines the Camel
6
6
xref:endpoint.adoc[Endpoint] to consume from.
7
7
8
-
IMPORTANT: The `@Consume` POJO annotations are not part of any Camel routes, and you cannot use errorHandler or onException with that.
9
-
10
-
[NOTE]
11
-
====
12
-
The following steps use the ActiveMQ component which is not yet supported on Camel 4.
13
-
====
8
+
IMPORTANT: The `@Consume` POJO annotations are not part of any Camel routes, and you cannot use xref:error-handler.adoc[errorHandler] or xref:exception-clause.adoc[onException] with this.
14
9
15
10
For example lets invoke the `onCheese()` method with the String body of the
16
11
inbound JMS message from ActiveMQ on the cheese
17
12
queue; this will use the xref:type-converter.adoc[Type Converter] to
18
-
convert the JMS ObjectMessage or BytesMessage to a String - or just use
19
-
a TextMessage from JMS
13
+
convert the JMS payload to `String` as declared in the method signature.
20
14
21
15
[source,java]
22
16
----
@@ -31,19 +25,19 @@ public class Foo {
31
25
32
26
The xref:bean-binding.adoc[Bean Binding] is then used to convert the
33
27
inbound xref:components:eips:message.adoc[Message] to the parameter list used to invoke
34
-
the method.
28
+
the method.
35
29
36
-
This basically creates a route that looks kinda like this:
30
+
This basically creates a route that looks kinda like this (based on the example above):
0 commit comments