[
https://issues.apache.org/jira/browse/NIFI-2957?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15654447#comment-15654447
]
ASF GitHub Bot commented on NIFI-2957:
--------------------------------------
Github user brosander commented on the issue:
https://github.com/apache/nifi/pull/1193
@jtstorck I'm having some problems trying to save a path (/node) and then
restore at the same path in a new zookeeper instance.
Here's what I'm getting (with a teardown and reinstantiation of the
zookeeper container between receive and send commands) :
```
zk-migrator.sh -z zoo1/node -r -f /out/out.json
zk-migrator.sh -z zoo1:2181/ -s -f /out/out.json
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in
[jar:file:/opt/nifi-toolkit/lib/logback-classic-1.1.3.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in
[jar:file:/opt/nifi-toolkit/lib/slf4j-log4j12-1.7.12.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an
explanation.
SLF4J: Actual binding is of type
[ch.qos.logback.classic.util.ContextSelectorStaticBinder]
2016-11-10 16:14:26,590 INFO [main] o.a.n.t.zkmigrator.ZooKeeperMigrator
Source data was obtained from ZooKeeper:
ZooKeeperEndpointConfig{connectString=zoo1, path=/node}
2016-11-10 16:14:26,621 INFO [ForkJoinPool.commonPool-worker-1]
o.a.n.t.zkmigrator.ZooKeeperMigrator transformed original node
DataStatAclNode{path=/node, acls=[31,s{'world,'anyone}
], ephemeralOwner=0} to DataStatAclNode{path=//node,
acls=[31,s{'world,'anyone}
], ephemeralOwner=0}
Exception in thread "main" java.lang.RuntimeException: unable to perform
operation: java.lang.IllegalArgumentException: Invalid path string "//node"
caused by empty node name specified @1
at
org.apache.nifi.toolkit.zkmigrator.ZooKeeperMigratorMain.main(ZooKeeperMigratorMain.java:145)
Caused by: java.util.concurrent.ExecutionException:
java.lang.IllegalArgumentException: Invalid path string "//node" caused by
empty node name specified @1
at
java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:357)
at
java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1895)
at
org.apache.nifi.toolkit.zkmigrator.ZooKeeperMigrator.writeZooKeeper(ZooKeeperMigrator.java:171)
at
org.apache.nifi.toolkit.zkmigrator.ZooKeeperMigratorMain.main(ZooKeeperMigratorMain.java:139)
Caused by: java.lang.IllegalArgumentException: Invalid path string "//node"
caused by empty node name specified @1
at
org.apache.zookeeper.common.PathUtils.validatePath(PathUtils.java:99)
at
org.apache.zookeeper.common.PathUtils.validatePath(PathUtils.java:35)
at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:766)
at
org.apache.nifi.toolkit.zkmigrator.ZooKeeperMigrator.ensureNodeExists(ZooKeeperMigrator.java:214)
at
org.apache.nifi.toolkit.zkmigrator.ZooKeeperMigrator.lambda$null$5(ZooKeeperMigrator.java:159)
at
java.util.concurrent.CompletableFuture.uniApply(CompletableFuture.java:602)
at
java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:577)
at
java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:474)
at
java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1595)
at
java.util.concurrent.CompletableFuture$AsyncSupply.exec(CompletableFuture.java:1582)
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
at
java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
at
java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
at
java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157)
```
> ZooKeeper migration toolkit
> ---------------------------
>
> Key: NIFI-2957
> URL: https://issues.apache.org/jira/browse/NIFI-2957
> Project: Apache NiFi
> Issue Type: New Feature
> Components: Tools and Build
> Affects Versions: 1.0.0, 0.7.1
> Reporter: Jeff Storck
> Assignee: Jeff Storck
> Fix For: 1.2.0
>
>
> When upgrading from NiFi 0.x to 1.x, or when it is desired to move from the
> embedded ZooKeeper to an external ZooKeeper, state from ZooKeeper needs to be
> migrated.
> Initial considerations:
> * Username/password protection of nodes is not supported in NiFi 1.x.. Those
> nodes that are configured that way in ZooKeeper need to be migrated to have
> an open ACL.
> * The toolkit will support a mode to read data from a configurable root node
> in a source ZooKeeper, and the data will be written to a file designated via
> CLI.
> * The toolkit will support a mode to write data to a destination ZooKeeper
> * The toolkit will not allow data to be written to the same ZooKeeper from
> which the source data was obtained.
> * The toolkit will not support reconnecting to ZooKeeper if it is
> disconnected. The user can rerun the tool.
> * The toolkit will support ZooKeepers configured with Kerberos.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)