Apache Camel 和 C 的架构建议
我正在尝试使用 Apache Camel,向我的老板提出它作为他正在推动的“ESB 解决方案”。 Camel 看起来是一个不错的项目,也是远离更重量级的东西的好方法。
我们有一个用 C 实现的低级层,它监听网络事件并应该触发一些演示 Camel 路由。进行此类集成的最佳方法是什么?我正在考虑 JMS 和 STOMP 协议,不幸的是它的 C 客户端库 看起来很有趣(其中之一就是你必须在 XCode 上编译它)。
您有其他建议吗?
I'm experimenting a bit with Apache Camel to propose it to my boss as an "ESB solution" which he is pushing for. Camel looks like a nice project, and a good way to keep away from more heavyweight stuff.
We've got a low-level layer implemented in C which listens to network events and is supposed to trigger some demo Camel route. Which is the best way to do such integration? I was thinking of JMS and STOMP protocol, unfortunately its C client library looks funny (you have to compile it on XCode, for one).
Have you got any alternatives to suggest?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
![扫码二维码加入Web技术交流群](/public/img/jiaqun_03.jpg)
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
有几个组件允许Camel与其他(非Java)应用程序交互。从顶部,camel-jetty,camel-jms, camel-file一个>和<一个href="http://camel.apache.org/amqp.html" rel="nofollow">camel-amqp 都可以轻松提供此功能。话虽这么说,我不是一个 C 人,所以我不确定从这个角度来看最好的选择...
如果你只是准备一个演示,只需使用定义一个 HTTP 端点(使用camel-jetty)来开始你的演示路线。随着您的进步,您可以切换到更强大的东西(JMS等)来在两者之间进行消息传递......
there are several components that allow Camel to interface with other (non-Java) applications. off the top, camel-jetty, camel-jms, camel-file and camel-amqp all provide this easily. that being said, I'm not a C guy, so I'm not sure the best choice from that perspective...
If you are just preparing a demo, just use define an HTTP endpoint (using camel-jetty) to kick off your demo route. As you progress, you can switch to something more robust (JMS, etc) for messaging between the two...
Camel 有一些组件(camel-netty、camel-mina) 可以提供较低级别的套接字交互。您可以考虑使用它们与您的系统对话。
Camel has some components (camel-netty, camel-mina) which can provide lower level socket interaction. You may consider to use them to talk to your system.
最后,我求助于使用 Java 网关,该网关使用我们的供应商(HP Tandem NonStop 大型机)提供的本机库接收内部 IPC 调用,并将它们转换为 JMS 消息,发送给在我的 PC 上运行的演示代理。
(我的第一步实际上是使用 HttpEndpoint)。
关于 Java 中的低级套接字库也有很好的建议,我们需要进行一些调整以避免 NonStop 上的标准网络库出现奇怪的行为。
Finally I resorted to using a Java Gateway which receives internal IPC calls using a native library provided by our vendor (HP Tandem NonStop mainframes) and translates them to JMS messages towards a demo broker running on my PC.
(My first step was actually to use HttpEndpoint).
Good advice also about low-level socket libraries in Java, we need some tuning to avoid weird behavior by standard network libraries on NonStop.