轻量级ESB——Mule

What is Mule ESB?

Mule, the runtime engine of Anypoint Platform, is a lightweight Java-based enterprise service bus (ESB) and integration platform that allows developers to connect applications together quickly and easily, enabling them to exchange data. It enables easy integration of existing systems, regardless of the different technologies that the applications use, including JMS, Web Services, JDBC, HTTP, and more. The ESB can be deployed anywhere, can integrate and orchestrate events in real time or in batch, and has universal connectivity.

The key advantage of an ESB is that it allows different applications to communicate with each other by acting as a transit system for carrying data between applications within your enterprise or across the Internet. Mule has powerful capabilities that include:

  • Service creation and hosting — expose and host reusable services, using the ESB as a lightweight service container
  • Service mediation — shield services from message formats and protocols, separate business logic from messaging, and enable location-independent service calls
  • Message routing — route, filter, aggregate, and re-sequence messages based on content and rules
  • Data transformation — exchange data across varying formats and transport protocols

Do I need an ESB?

Mule and other ESBs offer real value in scenarios where there are at least a few integration points or at least 3 applications to integrate. They are also well suited to scenarios where loose coupling, scalability and robustness are required.

Below is a quick ESB selection checklist. To read a much more comprehensive take on when to select an ESB, read this article written by MuleSoft founder and VP of Product Strategy Ross Mason: To ESB or not to ESB.

  • 1. Are you integrating 3 or more applications/services?
  • 2. Will you need to plug in more applications in the future?
  • 3. Do you need to use more than one type of communication protocol?
  • 4. Do you need message routing capabilities such as forking and aggregating message flows, or content-based routing?
  • 5. Do you need to publish services for consumption by other applications?

Why Mule?

Mule is lightweight but highly scalable, allowing you to start small and connect more applications over time. The ESB manages all the interactions between applications and components transparently, regardless of whether they exist in the same virtual machine or over the Internet, and regardless of the underlying transport protocol used.

There are currently several commercial ESB implementations on the market. However, many of these provide limited functionality or are built on top of an existing application server or messaging server, locking you into that specific vendor. Mule is vendor-neutral, so different vendor implementations can plug in to it. You are never locked in to a specific vendor when you use Mule.

Mule provides many advantages over competitors, including:

  • Mule components can be any type you want. You can easily integrate anything from a "plain old Java object" (POJO) to a component from another framework.
  • Mule and the ESB model enable significant component reuse. Unlike other frameworks, Mule allows you to use your existing components without any changes. Components do not require any Mule-specific code to run in Mule, and there is no programmatic API required. The business logic is kept completely separate from the messaging logic.
  • Messages can be in any format from SOAP to binary image files. Mule does not force any design constraints on the architect, such as XML messaging or WSDL service contracts.
  • You can deploy Mule in a variety of topologies, not just ESB. Because it is lightweight and embeddable, Mule can dramatically decrease time to market and increases productivity for projects to provide secure, scalable applications that are adaptive to change and can scale up or down as needed.
  • Mule's stage event-driven architecture (SEDA) makes it highly scalable. A major financial services company processes billions of transactions per day with Mule across thousands of Mule servers in a highly distributed environment.

Mule Enterprise

There are two editions of Mule: Community and Enterprise. Enterprise is the enterprise-class version of the ESB, with additional features and capabilities that are ideal for production deployments of Mule that have requirements for performance, HA, resiliency, or technical support. Mule Community and Enterprise are built on a common codebase, so it is easy to upgrade from Community to Enterprise. Learn more about Mule as an ESB Community vs. Mule ESB Enterprise.

以上摘自What is Mule ESB? | MuleSoft 官网

Summarize:

关于SOA(Service Orentied Architecture)面向服务架构,是企业通过服务整合来完成系统集成的一种思想,它并不是一种技术,而ESB就是从SOA的思想上发展而来的。

关于ESB(Enterprise Service Bus)企业服务总线,它是一种集成企业不同应用和不同系统的中介,它既为这些应用提供服务,同时也管理这些应用。它像一个管道一样打通企业各个应用之间的通道。比如说我们现在有8个APP,如果没有企业服务总线的存在,它们双向两两通信需要至少56个接口, 而当我们有ESB之后我们只需要和ESB进行通信。只需要16个接口即可。省去开发维护成本,增强了系统的性能和稳定性。

ESB是一种在松散耦合的服务和应用之间标准的集成方式。它可以作用于:

1面向服务架构:分布式应用之间的服务重用

2面向消息架构:应用之间通过ESB去发送接收消息

3面向事件驱动架构:应用之间异步的产生和接收消息

而Mule就是一种轻量级的ESB,它的特点是有很高的扩展性,允许从小规模开始,并随着时间的推移连接更多的应用程序。ESB 透明地管理应用程序和组件之间的所有交互,无论它们是存在于同一虚拟机中还是通过 Internet 存在,也无论使用的底层传输协议如何,它提供了消息路由和数据格式转换。

猜你喜欢

转载自blog.csdn.net/Lee_92/article/details/127034176
今日推荐