第 129 章 Guava EventBus Component


从 Camel 版本 2.10 开始提供

Google Guava EventBus 允许组件之间的发布订阅式通信,而无需组件明确相互注册(从而知道彼此)。guava-eventbus: 组件在 Camel 和 Google Guava EventBus 基础架构之间提供集成网桥。使用后者组件时,与 Guava EventBus 交换的消息可以透明地转发到 Camel 路由。EventBus 组件还允许将 Camel 交换的正文路由到 Guava EventBus

Maven 用户需要将以下依赖项添加到这个组件的 pom.xml 中:

<dependency>
    <groupId>org.apache.camel</groupId>
    <artifactId>camel-guava-eventbus</artifactId>
    <version>x.x.x</version>
    <!-- use the same version as your Camel core version -->
</dependency>
Copy to Clipboard Toggle word wrap

129.1. URI 格式

guava-eventbus:busName[?options]
Copy to Clipboard Toggle word wrap

其中 busName 代表 Camel registry 中的 com.google.common.eventbus.EventBus 实例的名称。

返回顶部
Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。 了解我们当前的更新.

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

Theme

© 2025 Red Hat