Uploaded image for project: 'ZooKeeper'
  1. ZooKeeper
  2. ZOOKEEPER-3881

org.apache.zookeeper.ZooKeeper.getData may throw NullPointerException when copyStat with null response stat.

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Critical
    • Resolution: Cannot Reproduce
    • Affects Version/s: 3.4.13
    • Fix Version/s: None
    • Component/s: java client
    • Labels:
      None
    • Environment:

      zookeeper-3.4.13

      Description

      We use curator 4.2.0 and zookeeper 3.4.13 as client, when we call curator PathChildrenCache.start(), It calls Zookeeper.getData(), but getData throw an NPE, please help check is it an BUG? Thanks.

      "2020-07-02 00:17:31,697" [UTC:20200702T001731+0700]|Error||DeployWorkThread-6|CONFIG > Failed to watch config of unit:ae9224e172952800c3b7a,type:global_configuration. com.huawei.itpaas.config.sdk.service.ConfigurationService.doCommonConfigWatcher(ConfigurationService.java:999)"2020-07-02 00:17:31,697" [UTC:20200702T001731+0700]|Error||DeployWorkThread-6|CONFIG > Failed to watch config of unit:ae9224e172952800c3b7a,type:global_configuration. com.huawei.itpaas.config.sdk.service.ConfigurationService.doCommonConfigWatcher(ConfigurationService.java:999)java.lang.NullPointerException: null at org.apache.zookeeper.server.DataTree.copyStat(DataTree.java:253) ~[zookeeper-3.4.13.fixed.20200331.jar:3.4.13--1] at org.apache.zookeeper.ZooKeeper.getData(ZooKeeper.java:1226) ~[zookeeper-3.4.13.fixed.20200331.jar:3.4.13--1] at org.apache.curator.framework.imps.GetDataBuilderImpl$4.call(GetDataBuilderImpl.java:327) ~[curator-framework-4.2.0.jar:4.2.0] at org.apache.curator.framework.imps.GetDataBuilderImpl$4.call(GetDataBuilderImpl.java:316) ~[curator-framework-4.2.0.jar:4.2.0] at org.apache.curator.connection.StandardConnectionHandlingPolicy.callWithRetry(StandardConnectionHandlingPolicy.java:64) ~[curator-client-4.2.0.jar:?] at org.apache.curator.RetryLoop.callWithRetry(RetryLoop.java:100) ~[curator-client-4.2.0.jar:?] at org.apache.curator.framework.imps.GetDataBuilderImpl.pathInForeground(GetDataBuilderImpl.java:313) ~[curator-framework-4.2.0.jar:4.2.0] at org.apache.curator.framework.imps.GetDataBuilderImpl.forPath(GetDataBuilderImpl.java:304) ~[curator-framework-4.2.0.jar:4.2.0] at org.apache.curator.framework.imps.GetDataBuilderImpl$2.forPath(GetDataBuilderImpl.java:145) ~[curator-framework-4.2.0.jar:4.2.0] at org.apache.curator.framework.imps.GetDataBuilderImpl$2.forPath(GetDataBuilderImpl.java:141) ~[curator-framework-4.2.0.jar:4.2.0] at org.apache.curator.framework.recipes.cache.PathChildrenCache.internalRebuildNode(PathChildrenCache.java:633) ~[curator-recipes-4.2.0.jar:4.2.0] at org.apache.curator.framework.recipes.cache.PathChildrenCache.rebuild(PathChildrenCache.java:335) ~[curator-recipes-4.2.0.jar:4.2.0] at org.apache.curator.framework.recipes.cache.PathChildrenCache.start(PathChildrenCache.java:304) ~[curator-recipes-4.2.0.jar:4.2.0] at com.huawei.itpaas.config.sdk.service.ConfigurationService.doCommonConfigWatcher(ConfigurationService.java:965) [com.huawei.itpaas.configservice.sdk-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.config.sdk.impl.ConfigPluginImpl.watchCommonGlobal(ConfigPluginImpl.java:383) [com.huawei.itpaas.configservice.sdk-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.plugin.configuration.support.ConfigMgmtImpl.watchFiles(ConfigMgmtImpl.java:374) [com.huawei.itpaas.agent.deploy.plugin-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.plugin.engine.commands.bind.BindCommand.watchFiles(BindCommand.java:196) [com.huawei.itpaas.agent.deploy.plugin-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.plugin.engine.commands.bind.BindCommand.importSchema(BindCommand.java:187) [com.huawei.itpaas.agent.deploy.plugin-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.plugin.engine.commands.bind.BindCommand.run(BindCommand.java:70) [com.huawei.itpaas.agent.deploy.plugin-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.plugin.engine.commands.bind.BindCommand.run(BindCommand.java:1) [com.huawei.itpaas.agent.deploy.plugin-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.engine.run.CommandRunner.runOneCommand(CommandRunner.java:246) [com.huawei.itpaas.agent.deploy.engine-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.engine.run.CommandRunner.access$1(CommandRunner.java:234) [com.huawei.itpaas.agent.deploy.engine-6.1.4-RELEASE.jar:?] at com.huawei.itpaas.agent.deploy.engine.run.CommandRunner$AsyncScheduler.run(CommandRunner.java:198) [com.huawei.itpaas.agent.deploy.engine-6.1.4-RELEASE.jar:?] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              gaofeng0147 FengGao
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: