执行 network-bootstrapper.jar 的正确结构是什么?

What is the proper structure for the execution of network-bootstrapper.jar?

我们的团队正在努力执行

`java -jar network-bootstrapper.jar <nodes-root-dir>` 

到bootstrap一个Corda节点。 Bootstrapping the network 上的文档指示 reader:

To use it, create a directory containing a node.conf file for each node >you want to create. Then run the following command:

java -jar network-bootstrapper.jar <nodes-root-dir>

For example running the command on a directory containing these files :

.
├── notary.conf             // The notary's node.conf file
├── partya.conf             // Party A's node.conf file
└── partyb.conf             // Party B's node.conf file

Would generate directories containing three nodes: notary, partya and partyb.

我们有

  1. 已创建根目录。
  2. 将网络-bootstrapper.jar放在根目录中。
  3. 创建了 notary.conf
  4. 创建了 partya.conf
  5. 已执行 java -jar network-bootstrapper.jar <nodes-root-dir>

这导致 "No nodes found."

查看 NetworkBootstrapper 源代码,我们发现文档不正确...

  1. 异常有点误导。对 'No nodes found' 异常的更正是将 corda.jar 放在 nodes-root-dir.
  2. 第 1 步让您更进一步。要解决的第二个问题是创建具有正确命名约定的 .conf 文件。文档表明节点(实体)的命名约定是 [node directory name].conf。 NetworkBootstrapper 代码库显示它期望的命名约定是 [node directory name]_node.config.

引导程序报告 No nodes found,因为节点的 node.conf 文件未以后缀 _node.config 结尾。正在更新文档以反映此拉取请求中的此要求:github.com/corda/corda/pull/2848.

evh69 的回答中列出的第一步 - 将 Corda JAR 放在节点文件夹中 - 不是必需的。引导程序将根据需要自动提取自己的 Corda JAR 副本。