我正在尝试通过以下链接在Corda中设置多公证人 https://github.com/corda/corda/tree/master/samples/notary-demo 在完成Windows命令行的所有三个步骤之后,我下载了带有mkit-m14分支的文件夹。在H2数据库中,没有像
这样的表[NOTARY_COMMITTED_STATES table (for Raft)
或
NODE_BFT_SMART_NOTARY_COMMITTED_STATES (for BFT)]
答案 0 :(得分:0)
我能够将其用于最新的Corda版本的新克隆中。
我将结果包括在这里,当使用release / os / 4.6分支时,它位于https://github.com/corda/corda的新克隆中。它也可以在release / os / 4.5分支上使用。
运行测试时,请务必使用./gradlew gradle包装器!
这就是我所做的:
davidawad@boron ~/D/raft-test>release/os/4.6>./gradlew samples:notary-demo:deployNodes
Starting a Gradle Daemon (subsequent builds will be faster)
> Configure project :
Java version: 1.8
Java source compatibility: 1.8
Java target compatibility: 1.8
Quasar version: 0.7.12_r3
Quasar classifier: jdk8
Building Corda version: 4.6-SNAPSHOT
> Task :confidential-identities:jar
Cordapp metadata not defined for this gradle build file. See https://docs.corda.net/head/cordapp-build-systems.html#separation-of-cordapp-contracts-flows-and-services
> Task :node:capsule:compileJava
Note: /Users/davidawad/Desktop/raft-test/node/capsule/src/main/java/CordaCaplet.java uses internal proprietary API that may be removed in a future release.
Note: Recompile with -Xlint:sunapi for details.
> Task :testing:testserver:compileJava
Note: /Users/davidawad/Desktop/raft-test/testing/testserver/src/main/java/CordaWebserverCaplet.java uses internal proprietary API that may be removed in a future release.
Note: Recompile with -Xlint:sunapi for details.
> Task :samples:notary-demo:deployNodesBFT
Running Cordform task
Deleting /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesBFT
Bootstrapping local test network in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesBFT
Generating node directory for NotaryService3
Generating node directory for NotaryService2
Generating node directory for AliceCorp
Generating node directory for NotaryService1
Generating node directory for NotaryService0
Waiting for all nodes to generate their node-info files...
... still waiting. If this is taking longer than usual, check the node logs.
> Task :samples:notary-demo:deployNodesBFT
Distributing all node-info files to all nodes
Loading existing network parameters... none found
Gathering notary identities
Generating contract implementations whitelist
New NetworkParameters {
minimumPlatformVersion=7
notaries=[NotaryInfo(identity=O=BFT, L=Zurich, C=CH, validating=false)]
maxMessageSize=10485760
maxTransactionSize=524288000
whitelistedContractImplementations {
}
eventHorizon=PT720H
packageOwnership {
}
modifiedTime=2020-06-25T21:45:42.014Z
epoch=1
}
Bootstrapping complete!
> Task :samples:notary-demo:deployNodesCustom
Running Cordform task
Deleting /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesCustom
Bootstrapping local test network in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesCustom
Generating node directory for AliceCorp
Generating node directory for NotaryService
Waiting for all nodes to generate their node-info files...
Distributing all node-info files to all nodes
Loading existing network parameters... none found
Gathering notary identities
Generating contract implementations whitelist
New NetworkParameters {
minimumPlatformVersion=7
notaries=[NotaryInfo(identity=O=Notary Service, L=Zurich, C=CH, validating=true)]
maxMessageSize=10485760
maxTransactionSize=524288000
whitelistedContractImplementations {
}
eventHorizon=PT720H
packageOwnership {
}
modifiedTime=2020-06-25T21:46:07.507Z
epoch=1
}
Bootstrapping complete!
> Task :samples:notary-demo:deployNodesRaft
Running Cordform task
Deleting /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft
Bootstrapping local test network in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft
Generating node directory for NotaryService2
Generating node directory for AliceCorp
Generating node directory for NotaryService1
Generating node directory for NotaryService0
Waiting for all nodes to generate their node-info files...
Distributing all node-info files to all nodes
Loading existing network parameters... none found
Gathering notary identities
Generating contract implementations whitelist
New NetworkParameters {
minimumPlatformVersion=7
notaries=[NotaryInfo(identity=O=Raft, L=Zurich, C=CH, validating=true)]
maxMessageSize=10485760
maxTransactionSize=524288000
whitelistedContractImplementations {
}
eventHorizon=PT720H
packageOwnership {
}
modifiedTime=2020-06-25T21:46:45.961Z
epoch=1
}
Bootstrapping complete!
> Task :samples:notary-demo:deployNodesSingle
Running Cordform task
Deleting /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesSingle
Bootstrapping local test network in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesSingle
Generating node directory for AliceCorp
Generating node directory for NotaryService
Waiting for all nodes to generate their node-info files...
Distributing all node-info files to all nodes
Loading existing network parameters... none found
Gathering notary identities
Generating contract implementations whitelist
New NetworkParameters {
minimumPlatformVersion=7
notaries=[NotaryInfo(identity=O=Notary Service, L=Zurich, C=CH, validating=true)]
maxMessageSize=10485760
maxTransactionSize=524288000
whitelistedContractImplementations {
}
eventHorizon=PT720H
packageOwnership {
}
modifiedTime=2020-06-25T21:47:09.766Z
epoch=1
}
Bootstrapping complete!
Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.4.1/userguide/command_line_interface.html#sec:command_line_warnings
BUILD SUCCESSFUL in 4m 51s
105 actionable tasks: 94 executed, 11 up-to-date
davidawad@boron ~/D/raft-test>release/os/4.6>./samples/notary-demo/build/nodes/nodesRaft/runnodes
base debug port set to: 5005
base monitoring port set to: 7005
Starting nodes in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft
Starting corda.jar in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService2 on debug port 5005
Node will expose jolokia monitoring port on 7005
Running command: osascript -e tell app "Terminal"
activate
delay 0.5
tell app "System Events" to tell process "Terminal" to keystroke "t" using command down
delay 0.5
do script "bash -c 'cd \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService2\" ; \"/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home/jre/bin/java\" \"-Dcapsule.jvm.args=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005 -javaagent:drivers/jolokia-jvm-1.6.0-agent.jar=port=7005,logHandlerClass=net.corda.node.JolokiaSlf4jAdapter\" \"-Dname=NotaryService2\" \"-jar\" \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService2/corda.jar\" && exit'" in selected tab of the front window
end tell
Starting corda.jar in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/AliceCorp on debug port 5006
Node will expose jolokia monitoring port on 7006
Running command: osascript -e tell app "Terminal"
activate
delay 0.5
tell app "System Events" to tell process "Terminal" to keystroke "t" using command down
delay 0.5
do script "bash -c 'cd \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/AliceCorp\" ; \"/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home/jre/bin/java\" \"-Dcapsule.jvm.args=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5006 -javaagent:drivers/jolokia-jvm-1.6.0-agent.jar=port=7006,logHandlerClass=net.corda.node.JolokiaSlf4jAdapter\" \"-Dname=AliceCorp\" \"-jar\" \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/AliceCorp/corda.jar\" && exit'" in selected tab of the front window
end tell
Starting corda.jar in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService0 on debug port 5007
Node will expose jolokia monitoring port on 7007
Running command: osascript -e tell app "Terminal"
activate
delay 0.5
tell app "System Events" to tell process "Terminal" to keystroke "t" using command down
delay 0.5
do script "bash -c 'cd \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService0\" ; \"/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home/jre/bin/java\" \"-Dcapsule.jvm.args=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5007 -javaagent:drivers/jolokia-jvm-1.6.0-agent.jar=port=7007,logHandlerClass=net.corda.node.JolokiaSlf4jAdapter\" \"-Dname=NotaryService0\" \"-jar\" \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService0/corda.jar\" && exit'" in selected tab of the front window
end tell
Starting corda.jar in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService1 on debug port 5008
Node will expose jolokia monitoring port on 7008
Running command: osascript -e tell app "Terminal"
activate
delay 0.5
tell app "System Events" to tell process "Terminal" to keystroke "t" using command down
delay 0.5
do script "bash -c 'cd \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService1\" ; \"/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home/jre/bin/java\" \"-Dcapsule.jvm.args=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5008 -javaagent:drivers/jolokia-jvm-1.6.0-agent.jar=port=7008,logHandlerClass=net.corda.node.JolokiaSlf4jAdapter\" \"-Dname=NotaryService1\" \"-jar\" \"/Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/NotaryService1/corda.jar\" && exit'" in selected tab of the front window
end tell
No file corda.jar found in /Users/davidawad/Desktop/raft-test/samples/notary-demo/build/nodes/nodesRaft/.cache
Started 4 processes
Finished starting nodes
davidawad@boron ~/D/raft-test>release/os/4.6>./gradlew samples:notary-demo:notarise
> Configure project :
Java version: 1.8
Java source compatibility: 1.8
Java target compatibility: 1.8
Quasar version: 0.7.12_r3
Quasar classifier: jdk8
Building Corda version: 4.6-SNAPSHOT
> Task :samples:notary-demo:notarise
Connecting to the recipient node (localhost:10003)
2020-06-25 17:50:12:517 -0400 [main] INFO net.corda.client.rpc.internal.RPCClient - Startup took 1167 msec
Notary: "O=Raft, L=Zurich, C=CH", with public key: DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Notarised 10 transactions:
Tx [10AE07..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [D59812..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [A72AA1..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [5B612F..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [48EA8D..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [688989..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [EEAAEF..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [AFC035..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [AC161A..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Tx [4221AF..] signed by DLHXqvQrTuQ5iUDGjNUue73AMxz256h8zDcFGB7MotS47k
Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.4.1/userguide/command_line_interface.html#sec:command_line_warnings
BUILD SUCCESSFUL in 15s
95 actionable tasks: 5 executed, 90 up-to-date
davidawad@boron ~/D/raft-test>release/os/4.6>
祝你好运!