Chapter 3. Transforming data with Camel

 

This chapter covers

  • Transforming data using EIPs and Java
  • Transforming XML data
  • Transforming using well-known data formats
  • Writing your own data formats for transformations
  • Understanding the Camel type-converter mechanism

In the previous chapter, we covered routing, which is the single most important feature any integration kit must provide. In this chapter, we’ll take a look at the second most important feature: data or message transformation.

Just as in the real world, where people speak different languages, the IT world speaks different protocols. Software engineers regularly need to act as mediators between various protocols when IT systems must be integrated. To address this, the data models used by the protocols must be transformed from one form to another, adapting to whatever protocol the receiver understands. Mediation and data transformation is a key feature in any integration kit, including Camel.

In this chapter, you’ll learn all about how Camel can help you with your data transformation challenges. We’ll start with a brief overview of data transformation in Camel and then look at how you can transform data into any custom format you may have. Then we’ll look at some Camel components that are specialized for transforming XML data and other well-known data formats. We’ll end the chapter by looking into Camel’s type-converter mechanism, which supports implicitly and explicitly type coercing.

3.1. Data transformation overview

3.2. Transforming data using EIPs and Java

3.3. Transforming XML

3.4. Transforming with data formats

3.5. Transforming with templates

3.6. About Camel type converters

3.7. Summary and best practices

sitemap