对ActiveMQ REST API的故障转移支持 [英] Failover support for activemq REST api

查看:116
本文介绍了对ActiveMQ REST API的故障转移支持的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用通过REST API的自定义消息Servlet来使用activemq。
对于消息检索,URL通常看起来像
http:// localhost:8161 / MessageServlet / MessageServlet?destination = queue://test.queue& clientId = Tester。

I am using activemq using a custom message servlet through REST api. For message retrieval url typically looks like "http://localhost:8161/MessageServlet/MessageServlet?destination=queue://test.queue&clientId=Tester".

我正在尝试使用纯主从模式合并故障转移机制( http://activemq.apache.org/pure-master-slave.html)。

I am trying incorporate failover mechanism using pure master slave mode("http://activemq.apache.org/pure-master-slave.html").

我已经配置了我的主从服务器,它正在使用jms连接运行。

I have already configured my master slave and it is running using jms connection.

我的问题是,当我出现故障时,我的故障转移URL应该是什么样的是uisng REST api。

My question is, what should be my failover url look like when i am uisng REST api.

预先感谢。

致谢,
Arijit

Regards, Arijit

推荐答案

从REST客户端的角度来看,您需要抽象请求(代理URL)或使用第三方处理客户端连接的故障转移库(请参见 HttpClient故障转移支持等)

From the REST client perspective, you'll need to abstract the requests (proxy URL) or handle the failover of the client connection using 3rd party libraries (see HttpClient failover support, etc.)

如果采用抽象方法,请考虑执行以下一项以下将请求转发给AMQ并提供故障转移支持...

If you go with the abstraction approach, then consider doing one of the following to proxy the requests to AMQ and provide failover support...

  • can you use Camel load balancer which supports endpoint failover support
  • use a 3rd party load balancer (Apache mod_proxy, perlbal, etc)

这篇关于对ActiveMQ REST API的故障转移支持的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆