2017-02-01 42 views
1

我在我的机器上的一个地窖组中有三个卡拉夫节点。第一个节点(lb_node)用作load_balancer,其他两个节点(1_node2_node)用作服务节点(具有部署的功能)。两个节点都有/service地址可用。我已经在群集上安装了cellar-http-balancer功能。另外,我在本地安装了样本功能1_node2_node
问题是,当我开始1_node2_node他们的服务没有正确登记在lb_node。从lb_nodehttp-list输出:HA卡拉夫地窖集群

ID | Servlet     | Servlet-Name | State  | Alias    | Url 
    103 | CellarBalancerProxyServlet | ServletModel-10 | Failed  | /features   | [/features/*] 
    103 | CellarBalancerProxyServlet | ServletModel-11 | Failed  | /jolokia   | [/jolokia/*] 
    103 | CellarBalancerProxyServlet | ServletModel-12 | Failed  | /gogo    | [/gogo/*] 
    103 | CellarBalancerProxyServlet | ServletModel-9 | Failed  | /instance   | [/instance/*] 
    103 | CellarBalancerProxyServlet | ServletModel-13 | Failed  | /services   | [/services/*] 
    103 | CellarBalancerProxyServlet | ServletModel-8 | Deployed | /jolokia   | [/jolokia/*] 
    103 | CellarBalancerProxyServlet | ServletModel-14 | Failed  | /system/console/res | [/system/console/res/*] 
    103 | CellarBalancerProxyServlet | ServletModel-15 | Failed  | /system/console  | [/system/console/*] 
    103 | CellarBalancerProxyServlet | ServletModel-3 | Deployed | /gogo    | [/gogo/*] 
    103 | CellarBalancerProxyServlet | ServletModel-2 | Deployed | /instance   | [/instance/*] 
    103 | CellarBalancerProxyServlet | ServletModel-7 | Deployed | /features   | [/features/*] 
    103 | CellarBalancerProxyServlet | ServletModel-6 | Deployed | /services   | [/services/*] 
    103 | CellarBalancerProxyServlet | ServletModel-5 | Deployed | /system/console  | [/system/console/*] 
    103 | CellarBalancerProxyServlet | ServletModel-4 | Deployed | /system/console/res | [/system/console/res/*] 

正如你可以看到只有一个节点的注册地址。当我在浏览器中输入lb_node url来检查来自其他节点的功能是否有效时,它会执行此操作。但是当我关闭已注册的节点时,lb_node将不再作为代理。它引发java.net.ConnectException: Connection refused

在教程https://karaf.apache.org/manual/cellar/latest-4/#_http_balancer有只有一个节点与服务和一个平衡器的情况下,这不是我的情况。

有没有什么办法通过使用卡拉夫和地窖实现http负载平衡的主动/主动群集?

+0

可以downvoter写他为什么这样做? –

回答

0

我把这个作为答案,因为我不能评论(没有声望),我没有回答你的问题,但它可以帮助你。

我发现this github项目,做我认为你试图实现的,我还没有测试过。

+0

感谢您的回复,但不幸的是,您提供的github项目并非主动/主动设置 - 主动/被动。这不是我想要的。 –