[
https://issues.apache.org/jira/browse/ZOOKEEPER-1950?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hongchao Deng updated ZOOKEEPER-1950:
-------------------------------------
Description:
The current implementation divide information of servers of legacy config into
two separate dynamic config files. There is a problem.
When we set "clientPort" variable in config file, it gets automatically erased
and later on there is no information about "clientPort" in either the old or
new (.dynamic) config file.
It becomes a serious problem when users of *3.4* jump to *3.5* directly without
changing their config: when a server crashes and restarts, there is no client
port serving.
For example,
a legacy config might look like:
```zoo.cfg
dataDir=/root/zookeeper/groupconfig/conf1/data
syncLimit=5
initLimit=10
tickTime=2000
clientPort=2181
server.1=127.0.0.1:2222:2223
server.2=127.0.0.1:3333:3334
server.3=127.0.0.1:4444:4445
```
After dynamic reconfig, it might look like
```zoo.cfg
dataDir=/root/zookeeper/groupconfig/conf1/data
syncLimit=5
tickTime=2000
initLimit=10
dynamicConfigFile=./zoo.cfg.dynamic
```
and
```zoo.cfg.dynamic
server.1=127.0.0.1:2222:2223:participant
server.2=127.0.0.1:3333:3334:participant
server.3=127.0.0.1:4444:4445:participant
version=e00000000
```
This could be successfully started at first time. But when server restarts from
crash, it never serve client port again.
was:
The current implementation divide information of servers of legacy config into
two separate dynamic config files. There is a problem.
When we set "clientPort" variable in config file, it gets automatically erased
and later on there is no information about "clientPort" in either the old or
new (.dynamic) config file.
It becomes a serious problem when users of *3.4* jump to *3.5* directly without
changing their config: when a server crashes and restarts, there is no client
port serving.
> configBackwardCompatibilityMode breaks compatibility
> ----------------------------------------------------
>
> Key: ZOOKEEPER-1950
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1950
> Project: ZooKeeper
> Issue Type: Bug
> Affects Versions: 3.5.0
> Reporter: Hongchao Deng
> Fix For: 3.5.0
>
>
> The current implementation divide information of servers of legacy config
> into two separate dynamic config files. There is a problem.
> When we set "clientPort" variable in config file, it gets automatically
> erased and later on there is no information about "clientPort" in either the
> old or new (.dynamic) config file.
> It becomes a serious problem when users of *3.4* jump to *3.5* directly
> without changing their config: when a server crashes and restarts, there is
> no client port serving.
> For example,
> a legacy config might look like:
> ```zoo.cfg
> dataDir=/root/zookeeper/groupconfig/conf1/data
> syncLimit=5
> initLimit=10
> tickTime=2000
> clientPort=2181
> server.1=127.0.0.1:2222:2223
> server.2=127.0.0.1:3333:3334
> server.3=127.0.0.1:4444:4445
> ```
> After dynamic reconfig, it might look like
> ```zoo.cfg
> dataDir=/root/zookeeper/groupconfig/conf1/data
> syncLimit=5
> tickTime=2000
> initLimit=10
> dynamicConfigFile=./zoo.cfg.dynamic
> ```
> and
> ```zoo.cfg.dynamic
> server.1=127.0.0.1:2222:2223:participant
> server.2=127.0.0.1:3333:3334:participant
> server.3=127.0.0.1:4444:4445:participant
> version=e00000000
> ```
> This could be successfully started at first time. But when server restarts
> from crash, it never serve client port again.
--
This message was sent by Atlassian JIRA
(v6.2#6252)