[
https://issues.apache.org/jira/browse/CURATOR-532?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16887258#comment-16887258
]
TisonKun commented on CURATOR-532:
----------------------------------
For the given case, I just notice that maven shade plugin would shade
{{Class.forName("org.apache.zookeeper.admin.ZooKeeperAdmin");}} into
{{Class.forName("org.apache.flink.shaded.org.apache.zookeeper.admin.ZooKeeperAdmin");}}
so it would be ok.
Keep open to see whether the abstract proposal "Manually configurable ZooKeeper
3.4.x compatibility" is valid.
> Manually configurable ZooKeeper 3.4.x compatibility
> ----------------------------------------------------
>
> Key: CURATOR-532
> URL: https://issues.apache.org/jira/browse/CURATOR-532
> Project: Apache Curator
> Issue Type: Improvement
> Components: Client, Framework
> Reporter: TisonKun
> Priority: Minor
>
> Currently, Curator auto detect whether it is in a zookeeper 3.4.x environment
> by
> {code:java}
> static {
> boolean localHasZooKeeperAdmin;
> try
> {
> Class.forName("org.apache.zookeeper.admin.ZooKeeperAdmin");
> localHasZooKeeperAdmin = true;
> }
> catch ( ClassNotFoundException e )
> {
> localHasZooKeeperAdmin = false;
> logger.info("Running in ZooKeeper 3.4.x compatibility mode");
> }
> hasZooKeeperAdmin = localHasZooKeeperAdmin;
> }
> {code}
> However, for some projects such as FLINK, both zookeeper and curator are
> relocated. Thus {{org.apache.zookeeper.admin.ZooKeeperAdmin}} is shaded as
> {{org.apache.flink.shaded.zookeeper.org.apache.zookeeper.admin.ZooKeeperAdmin}}.
> So the detection fails.
> A manually configurable compatibility option might solve this problem.
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)