[
https://issues.apache.org/jira/browse/CURATOR-578?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ying.li updated CURATOR-578:
----------------------------
Description:
I have a zookeeper cluster which run on a k8s cluster. and I use host name to
connect the zookeeper(like :
zookeeper-0.zookeeper-headless.default.svc.cluster.local:2181,zookeeper-1.zookeeper-headless.default.svc.cluster.local:2181,zookeeper-2.zookeeper-headless.default.svc.cluster.local:2181).
When the zookeeper restart. the zk pod's ip will change. then I find my
client will use the IP to recreate a client without using the hostname . but
the IP is not the latest IP from hostname.so, it will make client never connect
to zk , unless restart the client
After some debug ,I find the EnsembleTracker will change the connectString from
hostname to ip when receive the congfig change event. But in many case, the IP
get from hostname will not change after zk restart in k8s. so, it will make
client never connect to zk , unless restart the client
was:
I have a zookeeper cluster which run on a k8s cluster. and I use host name to
connect the zookeeper(like :
zookeeper-0.zookeeper-headless.default.svc.cluster.local:2181,zookeeper-1.zookeeper-headless.default.svc.cluster.local:2181,zookeeper-2.zookeeper-headless.default.svc.cluster.local:2181).
When the zookeeper restart. the zk pod's ip will change. then I find my
client will use the IP to recreate a client without using the hostname .
After some debug ,I find the EnsembleTracker will change the connectString from
hostname to ip when receive the congfig change event. But in many case, the IP
get from hostname will not change after zk restart in k8s. so, it will make
client never connect to zk , unless restart the client
> EnsembleTracker replace hostname connectString with wrong ip from zk config
> ---------------------------------------------------------------------------
>
> Key: CURATOR-578
> URL: https://issues.apache.org/jira/browse/CURATOR-578
> Project: Apache Curator
> Issue Type: Bug
> Components: Client
> Affects Versions: 4.0.1
> Reporter: ying.li
> Priority: Major
>
> I have a zookeeper cluster which run on a k8s cluster. and I use host name
> to connect the zookeeper(like :
> zookeeper-0.zookeeper-headless.default.svc.cluster.local:2181,zookeeper-1.zookeeper-headless.default.svc.cluster.local:2181,zookeeper-2.zookeeper-headless.default.svc.cluster.local:2181).
>
> When the zookeeper restart. the zk pod's ip will change. then I find my
> client will use the IP to recreate a client without using the hostname . but
> the IP is not the latest IP from hostname.so, it will make client never
> connect to zk , unless restart the client
>
> After some debug ,I find the EnsembleTracker will change the connectString
> from hostname to ip when receive the congfig change event. But in many case,
> the IP get from hostname will not change after zk restart in k8s. so, it
> will make client never connect to zk , unless restart the client
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)