Message Broker
• A message broker is an architectural pattern for message validation, message transformation and message routing. It mediates communication amongst applications, minimizing the mutual awareness that applications should have of
each other in order to be able to exchange messages
• message brokers can accomplish how the information is represented or accessed
• They also provide a mechanism to integrate multiple business processes
• Message brokers bridge many different platforms and application development solutions. They are also able to connect to each application and to route information between applications
• Message brokers often provide "message transformation"
engines, allowing the message broker to alter the way information is represented for each application
• Other features of the message broker may include
rules-processing capabilities (the ability to apply rules to the transformation and routing of information), and intelligent routing capabilities (the ability to identify messages, as well as the ability to route them to the appropriate location)
• The services provided by message brokers can be put into several distinct categories:
» message transformation, rules processing, intelligent routing, message warehousing, flow control, repository services, directory services, management, APIs, and adapters.
• Message brokers are able to integrate many different types of middleware,as well as applications and
databases.
• components of a business integration solution are
neither middleware nor applications. They are routing, reformatting, and flow components.
• Message brokers have three primary components:
» the message transformation layer,
» the rules engine, and
» the intelligent routing mechanism.
• A message broker is a software system based on asynchronous, store-and-forward messaging.
• A complete message-brokering solution demands an underlying messaging system, a brokering layer (or
"rules engine"), a connectivity (adapter) framework, design and development tools, and system
management and administration tools.
• The first step in evaluating a message broker must include an evaluation of the types of systems to be integrated.
• message brokers interface with source and target
applications at the data level, the application interface level, the method level, and the user interface level.
This reality indicates that source and target systems may be any number of entities.
• Message brokers provide services to applications
through an application programming interface, or an adapter.
• Message Transformation Layer
• The message transformation layer understands the format of all messages being passed among the applications. The data from one message is
restructured into a new message that makes sense to the receiving application.
• It provides a common dictionary that contains
information on how each application communicates outside itself (application externalization), as well as which pieces of information have meaning to which applications
• Message transformation layers generally store
application information in a repository that keeps track of the source system, the format of the message, the target system, and the desired format of the target system.
• Schema Conversions
• A schema conversion is the process of changing the structure of a message, and thus remapping the
schema, so that it is acceptable for the target system.
• Intelligent Routing
• Intelligent routing, sometimes referred to as "flow control"
or "content-based routing
• In this scenario, the message broker can identify a message coming from the source application and route it to the
proper target application, transforming it if required.
• For example, when a message arrives at the message broker, it is analyzed and identified as coming from a
particular system and/or subsystem. Once the message is identified, and the message schema is understood, the applicable rules and services are applied to the processing of the message, including message transformation. Once processed, the message broker, based on how it is
programmed, will route the message to the correct target system
Intelligent routing means identifying the message and sending it on to the proper destination
• Rules Processing
• The rules-processing engine, found within most message brokers, provides the EAI architect and
developer with the ability to create rules to control the processing and distribution of messages
• In short, rules processing is an application development environment supported by the message broker to
address the special requirements of integrating applications.
• For example, at times a message may be required by a second target application. At other times a message will have to be routed to two or more applications. In order to address each situation, messages should be able to be routed to any number of target applications that extract and transform data from any number of source applications. A truly flexible solution requires a rules engine to make these formatting and routing decisions dynamically. Combining a rules engine with a message transformation layer allows for such a solution to be realized.
• Message Warehousing
• Another feature of message brokers is message
warehousing. A message warehouse is a database that, as an option, is able to store messages that flow
through the message broker
• message brokers provide this message persistence
facility to meet several requirements: message mining, message integrity, message archiving, and auditing.
• Message mining implies that the message warehouse is a quasi-data warehouse, allowing for the extraction of business data to support decisions.
• For example, it is possible to use the message warehouse to determine the characteristics, and amount, of new customer information that is being processed through the message broker. All new sales orders for a given period of time can be displayed.
• Message warehousing is able to provide services such as message integrity because the warehouse itself provides a natural, persistent state for message traffic.
• If the server goes down, the message warehouse may act as a persistent buffer, or queue, to store messages that would otherwise be lost.
• Message archiving provides the message broker user with the ability to store months of message traffic in an archive for auditing or other purposes.
• For example, it might be useful at one point in the future to be able to look back and examine the message traffic of a particular day.
• Auditing means using the message warehouse to
determine the health of the EAI solution, and provides the ability to solve problems.
• For example, by using the auditing facilities of a
message broker, one can determine message traffic loads, message content variations, and the number of messages requiring transformation.
• Auditing also tracks messages that change, the state before the transformation, and the state following.
• Repository Services
• Today, many message brokers embrace the concept of a repository, a database of information about source and target applications, which may include data elements, inputs, processes, outputs, and the inter-relationships among applications.
• EAI-enabled repositories, in their simplest
form, provide the message broker user with a database of information pertaining to:
• Location of system (directory)
• Security parameters
• Message schema information
• Metadata
• Enabling technology
• Transformation information
• Rules and logic for message processing
• Design and architecture information (e.g., UML)
• Object information
• Topologies
• message brokers use a hub-and-spoke topology. The message broker, as hub, rests between the source and target applications being integrated in a configuration that resembles a star
In the bus configuration, the message broker sits on the network bus and provides message broker services to other systems on the bus
In the multihub configuration, a number of message brokers are linked, with the source and target applications linked to any of the brokers in the configuration