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: src/reference/asciidoc/content-enrichment.adoc
+2-6Lines changed: 2 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -314,11 +314,7 @@ Optional.
314
314
<6> By default, the original message's payload is used as payload that is sent to the `request-channel`.
315
315
By specifying a SpEL expression as the value for the `request-payload-expression` attribute, you can use a subset of the original payload, a header value, or any other resolvable SpEL expression as the basis for the payload that is sent to the request-channel.
316
316
For the expression evaluation, the full message is available as the 'root object'.
317
-
For instance, the following SpEL expressions (among others) are possible:
318
-
* `payload.something`
319
-
* `headers.something`
320
-
* `new java.util.Date()`
321
-
* `'thing1' + 'thing2'`
317
+
For instance, the following SpEL expressions (among others) are possible: `payload.something`, `headers.something`, `new java.util.Date()`, `'thing1' + 'thing2'`
322
318
<7> Channel where a reply message is expected.
323
319
This is optional.
324
320
Typically, the auto-generated temporary reply channel suffices.
@@ -343,7 +339,7 @@ Optional.
343
339
<12> Each `property` sub-element provides the name of a property (through the mandatory `name` attribute).
344
340
That property should be settable on the target payload instance.
345
341
Exactly one of the `value` or `expression` attributes must be provided as well -- the former for a literal value to set and the latter for a SpEL expression to be evaluated.
346
-
The root object of the evaluation context is the message that was returned from the flow initiated by this enricher -- the input message if there is no request channel or the application context (using the '@<beanName>.<beanProperty>' SpEL syntax).
342
+
The root object of the evaluation context is the message that was returned from the flow initiated by this enricher -- the input message if there is no request channel or the application context (using the `@<beanName>.<beanProperty>` SpEL syntax).
347
343
Starting with version 4.0, when specifying a `value` attribute, you can also specify an optional `type` attribute.
348
344
When the destination is a typed setter method, the framework coerces the value appropriately (as long as a `PropertyEditor`) exists to handle the conversion.
349
345
If, however, the target payload is a `Map`, the entry is populated with the value without conversion.
Copy file name to clipboardExpand all lines: src/reference/asciidoc/transformer.adoc
+5-29Lines changed: 5 additions & 29 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,7 +18,7 @@ For more information on those transformers, see <<./xml.adoc#xml,XML Support - D
18
18
==== Configuring a Transformer with XML
19
19
20
20
The `<transformer>` element is used to create a message-transforming endpoint.
21
-
In addition to `input-channel` and `output-channel` attributes, it requires a ` attribute`.
21
+
In addition to `input-channel` and `output-channel` attributes, it requires a `ref` attribute.
22
22
The `ref` may either point to an object that contains the `@Transformer` annotation on a single method (see <<transformer-annotation>>), or it may be combined with an explicit method name value provided in the `method` attribute.
23
23
24
24
====
@@ -70,7 +70,7 @@ The following example shows how to use a SpEL expression:
@@ -99,7 +99,7 @@ Whereas that channel adapter only supports `String`, byte-array, or `java.io.Fil
99
99
That works fine as long as the result of the `toString()` call is what you want to be written to the file.
100
100
Otherwise, you can provide a custom POJO-based transformer by using the generic 'transformer' element shown previously.
101
101
102
-
TIP: When debugging, this transformer is not typically necessary, since the 'logging-channel-adapter' is capable of logging the message payload.
102
+
TIP: When debugging, this transformer is not typically necessary, since the `logging-channel-adapter` is capable of logging the message payload.
103
103
See <<./channel.adoc#channel-wiretap,Wire Tap>> for more detail.
104
104
105
105
[NOTE]
@@ -122,7 +122,7 @@ For more sophistication (such as selection of the charset dynamically, at runtim
122
122
====
123
123
124
124
If you need to serialize an `Object` to a byte array or deserialize a byte array back into an `Object`, Spring Integration provides symmetrical serialization transformers.
125
-
These use standard Java serialization by default, but you can provide an implementation of Spring 3.0's serializer or seserializer strategies by using the 'serializer' and 'deserializer' attributes, respectively.
125
+
These use standard Java serialization by default, but you can provide an implementation of Spring 3.0's serializer or seserializer strategies by using the `serializer` and `deserializer` attributes, respectively.
126
126
The following example shows to use Spring's serializer and deserializer:
127
127
128
128
====
@@ -194,7 +194,7 @@ public class Kid {
194
194
----
195
195
====
196
196
197
-
If you need to create a "`structured`" map, you can provide the 'flatten' attribute.
197
+
If you need to create a "`structured`" map, you can provide the `flatten` attribute.
198
198
The default is 'true'.
199
199
If you set it to 'false', the structure is a `Map` of `Map` objects.
200
200
@@ -345,31 +345,7 @@ Beginning with version 3.0, the `object-mapper` attribute references an instance
345
345
This abstraction lets multiple implementations of JSON mappers be used.
346
346
Implementation that wraps https://github.com/FasterXML[Jackson 2] is provided, with the version being detected on the classpath.
347
347
The class is `Jackson2JsonObjectMapper`, respectively.
348
-
349
-
NOTE: The `BoonJsonObjectMapper` is deprecated in 5.2 since the library is out of support.
350
-
====
351
-
352
-
[IMPORTANT]
353
348
====
354
-
If you have requirements to use both Jackson and Boon in the same application, keep in mind that, before version 3.0, the JSON transformers used only Jackson 1.x.
355
-
From 4.1 on, the framework selects Jackson 2 by default.
356
-
Jackson 1.x is no longer supported by the framework internally.
357
-
However, you can still use it within your code by including the necessary library.
358
-
To avoid unexpected issues with JSON mapping features when you use annotations, you may need to apply annotations from both Jackson and Boon on domain classes, as the following example shows:
0 commit comments