【发布时间】:2021-05-08 02:00:51
【问题描述】:
我有一个使用 Camel 的 SpringBoot 应用程序,我想使用 Google PubSub 组件将消息推送到主题。但是,当我的代码通过以下方式使用 ProducerTemplate 到 PubSub 时:
producer.sendBody("google-pubsub://<my-project-id>:<my-topic-name>");
我得到 com.google.api.client.repackaged.com.google.common.base.Strings 的 NoClassDefFoundErr。
在我的 build.gradle 我有:
编译组:'org.apache.camel',名称:'camel-google-pubsub',版本:camelVersion
编译组:'org.apache.camel.springboot',名称:'camel-google-pubsub-starter',版本:camelVersion
我到处寻找解决方案。我已经在 Maven 存储库中搜索了任何可能有这个 Strings 类但没有运气的 jar。
谁能提出解决方案?
谢谢。
【问题讨论】:
标签: spring-boot apache-camel google-cloud-pubsub