Open-Source ESBs in Action
Example Implementations in Mule and ServiceMix
Tijs Rademakers and Jos Dirksen
  • September 2008
  • ISBN 9781933988214
  • 528 pages
  • printed in black & white

A great book for any ESB practitioner.

Rick Wagner, Acxiom Corporation

Choice is usually a good thing for consumers but it can be difficult to navigate the landscape of Open Source ESBs. I believe this book is extremely valuable for readers looking to choose an ESB and looking to get a stronger grasp on how to implement an ESB using open source projects. I found the case studies in section III particularly useful since they pull together many of the concepts learned throughout the book.

This book guides the reader through a logical journey of discovery and demonstration to deliver a solid understanding of the core ESB concepts and how they can be used in the real world. Armed with this book and the wealth of open source projects available I think the reader will be ready to take on any ESB project. Open Source made ESBs a lot more fun, go and enjoy yourself!

—From the Foreword by Ross Mason, Creator of the Mule Project

Open-Source ESBs in Action describes how to use ESBs in real-world situations. You will learn how the various features of an ESB such as transformation, routing, security, connectivity, and more can be implemented on the example of two open-source ESB implementations: Mule and ServiceMix. The authors first introduce ServiceMix and Mule, and then present general principles and patterns of ESB use, as well as a structured approach to solving common integration problems, through examples using them.

Table of Contents show full

foreword

foreword

preface

acknowledgments

about this book

Part 1 Understanding ESB functionality

1. The world of open source ESBs

1.1. Why do you need an ESB?

Benefits of an ESB

Using an ESB from an application perspective

1.2. Explaining the core functionalities of an ESB

Location transparency

Transport protocol conversion

Message transformation

Message routing

Message enhancement

Security

Monitoring and management

Core functionality overview

1.3. Researching the open source ESB market

Demystifying the open source ESB

Overview of open source ESBs

1.4. Why did we choose Mule and ServiceMix?

Defining selection criteria

Assessing the open source ESBs

1.5. Hello world with Mule and ServiceMix

Taking a donkey ride with Mule

Taking a JBI dive with ServiceMix

1.6. Summary

2. Architecture of Mule and

2.1. Mule architecture and components

Mule components overview

Mule endpoints

Transformers

Routers

Component

Mule deployment models

Mule wrap-up

2.2. JBI, the foundation for ServiceMix

Service engines and binding components

Services and endpoints

Normalized message router

Service description, invocation, and message exchanges

Service unit and service assembly

JBI wrap-up

2.3. ServiceMix architecture and components

ServiceMix overview

Routing and transformations in ServiceMix

ServiceMix deployment models

ServiceMix wrap-up

2.4. Summary

3. Setting up the Mule and ServiceMix

3.1. Three technologies enhancing the ESB functionality

Using Spring as an object container

XML marshaling with JiBX

Using JMS with the ActiveMQ broker

3.2. Preparing the development environment

Setting up ESBs, tools, and required libraries

Running examples from Eclipse

3.3. Inaugurate the Mule environment

Writing and configuring the Mule components

Running the Mule example

3.4. Inaugurate the ServiceMix environment

Select the necessary JBI components

Configuring the ServiceMix example implementation

Running the ServiceMix example

3.5. Summary

4. The foundation of an integration solution

4.1. Implementing integration logic with Mule

Creating a logging solution with Mule

Developing a custom transformer with Mule

Integrating Mule and Spring

4.2. Implementing integration logic with ServiceMix

Creating a logging service assembly for ServiceMix

Creating service units and a service assembly

Integrating ServiceMix and Spring

4.3. Constructing message flows with an ESB

What is a message flow?

A message flow case study

4.4. Implementing a message flow with Mule

Implementing the request flow with Mule

Implementing the response flow with Mule

4.5. Implementing a message flow with ServiceMix

Implementing the request flow with ServiceMix

Implementing the response flow with ServiceMix

4.6. Interlude: Spring Integration

A quick example with Spring Integration

4.7. Summary

Part 2 Using ESB core functionalities

5. Working with messages

5.1. Routing messages

Fixed router

Content-based router

5.2. Validating messages

Validating messages with Mule

Validating messages with ServiceMix

An alternative way to perform message validation using Synapse

5.3. Transforming messages

Implementing message transformation in Mule

Implementing message transformation in ServiceMix

5.4. Summary

6. Connectivity options

6.1. File connectivity

Mule File transport

ServiceMix file transport

6.2. Connecting to JMS

Connecting Mule to JMS

Connecting ServiceMix to JMS

6.3. Connecting to a database using JDBC

Connecting Mule to JDBC

Connecting ServiceMix to JDBC

6.4. Connecting to mail servers

Connecting Mule to POP3 and SMTP

Connecting ServiceMix to POP3 and SMTP

6.5. FTP connectivity

FTP and Mule

FTP and ServiceMix

6.6. Connecting to EJB 3

Using EJB 3 from Mule

EJB 3 and ServiceMix

6.7. Summary

7. Web services support

7.1. Top-down approach web service

Java implementation of the web service

Implementing a top-down web service using Mule

Implementing a top-down web service using ServiceMix

7.2. Bottom-up approach

Bottom-up approach using Mule

Bottom-up approach using ServiceMix

7.3. Consuming web services

Consuming web services with Mule

Consuming web services using ServiceMix

7.4. Web service standards

WS-Security

Using WS-Security with Mule

Using WS-Security with ServiceMix

WS-Addressing

Using WS-Addressing in Mule

Using WS-Addressing in ServiceMix

7.5. Summary

8. Implementing enterprise-quality message flows

8.1. Handling errors in your message flow

Error handling with Mule

Error handling in ServiceMix

8.2. Securing the ESB environment

Authentication and authorization with Mule

Authentication and authorization with ServiceMix

8.3. Making your message flows transactional

Implementing transactional message flows in Mule

Implementing transactional message flows in ServiceMix

8.4. Summary

Part 3 ESB case studies

9. Implementing a case study using

9.1. Introducing a design approach for integration projects

Introducing the Enterprise Integration patterns

Analyzing a pattern-based design approach

9.2. Introducing a restaurant table reservation case study

9.3. Designing the restaurant table reservation solution

Designing a publish-subscribe message flow

Designing a filtering and routing message flow

9.4. Implementing the case study with Mule and ServiceMix

The Spring and Hibernate building blocks

Implementing the Mule message flow

Implementing the ServiceMix message flow

9.5. Testing and deploying the integration solution

Using JUnit to test the Mule and ServiceMix flows

Deploying an integration solution to a production environment

9.6. Summary

10. Managing and monitoring the ESB

10.1. System-management Enterprise Integration patterns

The Wire Tap pattern

The Message Store pattern

The Detour pattern

10.2. Monitoring using JMX

Using JMX to administer Mule

Monitoring Mule using MC4J

Mule Galaxy and Mule HQ

Using JMX to administer ServiceMix

Monitoring ServiceMix using MC4J

10.3. Summary

11. Implementing a process engine in the ESB

11.1. Introducing the process engine

The execution environment for processes

Designing processes for a process engine

11.2. A process engine case study: booking a day of scuba diving

11.3. Diving into the messages and services

Designing the case study message definitions

Serializing the case study messages to XML with JiBX

Setting the stage for the case study implementation

11.4. Implementing a process engine with jBPM and jPDL

Orchestrating services with jPDL

Implementing the case study with jBPM and Mule

11.5. Implementing a process engine with Apache ODE and WS-BPEL

Orchestrating services with WS-BPEL

Implementing the case study with Apache ODE and ServiceMix

11.6. Summary

Appendix A: ServiceMix 4.0

Appendix B: Differences between Mule 1.4.x and Mule 2.0.x

Appendix C: Graphical tool support

Appendix D: Mule component overview

Appendix E: ServiceMix component overview

Appendix F: The Swing test client

Appendix G: Overview of tools and libraries

index

About the Technology

The need for enterprise integration is widespread for the simple reason that businesses require independent applications to exchange information with each other. A CRM application must know about the order history of a customer, but that history is stored in the sales application. A technology that companies increasingly use to integrate enterprise applications is the Enterprise Service Bus (ESB).

About the book

Working in integration projects is exciting, with new technologies and paradigms arriving every day. In this area, open source is playing a more and more dominant role with projects such as Mule and ServiceMix. Open-Source ESBs in Action will help you to learn open-source integration technologies quickly and will provide you with knowledge that you can use to effectively work with Mule and ServiceMix.

What's inside

  • Numerous code examples
  • Detailed explanation on how to use Mule and ServiceMix
  • Practical, real-world examples and case studies
  • Integration with a full open source tool stack

About the authors

Tijs Rademakers is a software architect with more than six years of experience in designing and developing Java and EE applications. He works for Atos Origin, a large European system integrator, where he is responsible for SOA and BPM services and knowledge development. Tijs has designed and implemented large process- and application-integration solutions, primarily focused on open standards. He has extensive product knowledge of open source as well as closed source SOA and enterprise integration tools, including Mule, ServiceMix, jBPM, and WebSphere Process Server. Tijs is a regular speaker at Java conferences, where he talks about open source integration topics like Mule and ServiceMix. Tijs lives in the Netherlands near Eindhoven with his girlfriend and his new daughter, Liv.

Jos Dirksen has been working with Java and J2EE applications for more than six years as a software architect. The last couple of years, his focus topics have been open source, security, and quality. He has worked with various open source and commercial integration solutions, mostly in the government and the healthcare areas. Jos has a lot of project experience working with Mule, Apache Synapse, and Apache Axis2 and has also completed projects based on the integration tooling from IBM. Jos regularly gives presentation on open source, Mule, and other related topics. He lives in Eindhoven, the Netherlands, with his wife.


combo $44.99 pBook + eBook
eBook $35.99 pdf + ePub + kindle

FREE domestic shipping on three or more pBooks

A must-have ESB resource!

Craig Borysowich, Imagination Edge, Inc.

The most comprehensive content that I've seen on open source ESBs.

Rodney Biresch, Chariot Solutions

The Bible for integration architects.

Davide Piazza, Omnys s.r.l.

...ample code samples and excellent descriptions.

Jeff Davis, HireRight, Inc.

This book will take you to a new level.

Christian Siegers, Stater International Mortgage Services