Corda-验证公证人抛出java.lang.IllegalArgumentException

时间:2019-01-09 11:50:44

标签: java exception corda

我从验证公证人处收到以下异常:

  

java.lang.IllegalArgumentException:一个无效的Java名称:   java.util.Set

MyClass位于州/合同罐中

堆栈跟踪

java.io.NotSerializableException: Unexpected throwable: net.corda.core.transactions.WireTransaction -> net.corda.core.transactions.WireTransaction -> null java.lang.reflect.InvocationTargetException: net.corda.core.transactions.WireTransaction -> net.corda.core.transactions.WireTransaction -> null
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
    at net.corda.nodeapi.internal.serialization.amqp.ObjectSerializer.construct(ObjectSerializer.kt:138)
    at net.corda.nodeapi.internal.serialization.amqp.ObjectSerializer.readObjectBuildViaConstructor(ObjectSerializer.kt:97)
    at net.corda.nodeapi.internal.serialization.amqp.ObjectSerializer.readObject(ObjectSerializer.kt:82)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObject$node_api(DeserializationInput.kt:135)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObjectOrNull$node_api(DeserializationInput.kt:109)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObjectOrNull$node_api$default(DeserializationInput.kt:108)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput$deserialize$1.invoke(DeserializationInput.kt:98)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.des(DeserializationInput.kt:80)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.deserialize(DeserializationInput.kt:96)
    at net.corda.nodeapi.internal.serialization.amqp.AbstractAMQPSerializationScheme.deserialize(AMQPSerializationScheme.kt:123)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1$1.invoke(SerializationScheme.kt:111)
    at net.corda.core.serialization.SerializationFactory.withCurrentContext(SerializationAPI.kt:66)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:111)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:86)
    at net.corda.core.serialization.SerializationFactory.asCurrent(SerializationAPI.kt:80)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl.deserialize(SerializationScheme.kt:111)
    at net.corda.core.transactions.SignedTransaction.getCoreTransaction(SignedTransaction.kt:272)
    at net.corda.core.transactions.SignedTransaction.getInputs(SignedTransaction.kt:71)
    at net.corda.node.services.transactions.ValidatingNotaryFlow.receiveTransaction(ValidatingNotaryFlow.kt:50)
    at net.corda.node.services.transactions.ValidatingNotaryFlow.receiveAndVerifyTx(ValidatingNotaryFlow.kt:30)
    at net.corda.core.flows.NotaryFlow$Service.call(NotaryFlow.kt:142)
    at net.corda.core.flows.NotaryFlow$Service.call(NotaryFlow.kt:133)
    at net.corda.node.services.statemachine.FlowStateMachineImpl.run(FlowStateMachineImpl.kt:96)
    at net.corda.node.services.statemachine.FlowStateMachineImpl.run(FlowStateMachineImpl.kt:44)
    at co.paralleluniverse.fibers.Fiber.run1(Fiber.java:1092)
    at co.paralleluniverse.fibers.Fiber.exec(Fiber.java:788)
    at co.paralleluniverse.fibers.RunnableFiberTask.doExec(RunnableFiberTask.java:100)
    at co.paralleluniverse.fibers.RunnableFiberTask.run(RunnableFiberTask.java:91)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at net.corda.node.utilities.AffinityExecutor$ServiceAffinityExecutor$1$thread$1.run(AffinityExecutor.kt:62)
Caused by: java.lang.Exception: Malformed transaction, OUTPUTS_GROUP at index 0 cannot be deserialised
    at net.corda.core.transactions.TraversableTransaction.deserialiseComponentGroup(MerkleTransaction.kt:70)
    at net.corda.core.transactions.TraversableTransaction.<init>(MerkleTransaction.kt:25)
    at net.corda.core.transactions.WireTransaction.<init>(WireTransaction.kt:43)
    ... 39 more
Caused by: java.io.NotSerializableException: Unexpected throwable: Not a valid Java name: java.util.Set<com.tradeix.concord.domain.models.FundingResponseInvoiceProposal> java.lang.IllegalArgumentException: Not a valid Java name: java.util.Set<com.tradeix.concord.domain.models.FundingResponseInvoiceProposal>
    at net.corda.nodeapi.internal.serialization.carpenter.ClassCarpenter.validateSchema(ClassCarpenter.kt:410)
    at net.corda.nodeapi.internal.serialization.carpenter.ClassCarpenter.build(ClassCarpenter.kt:106)
    at net.corda.nodeapi.internal.serialization.carpenter.MetaCarpenterBase.step(MetaCarpenter.kt:69)
    at net.corda.nodeapi.internal.serialization.carpenter.MetaCarpenter.build(MetaCarpenter.kt:98)
    at net.corda.nodeapi.internal.serialization.amqp.SerializerFactory.processSchema(SerializerFactory.kt:235)
    at net.corda.nodeapi.internal.serialization.amqp.SerializerFactory.processSchema$default(SerializerFactory.kt:216)
    at net.corda.nodeapi.internal.serialization.amqp.SerializerFactory$get$1.invoke(SerializerFactory.kt:185)
    at net.corda.nodeapi.internal.serialization.amqp.SerializerFactory$get$1.invoke(SerializerFactory.kt:40)
    at net.corda.nodeapi.internal.serialization.amqp.SerializerFactory.get(SerializerFactory.kt:184)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObject$node_api(DeserializationInput.kt:131)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObjectOrNull$node_api(DeserializationInput.kt:109)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObjectOrNull$node_api$default(DeserializationInput.kt:108)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput$deserialize$1.invoke(DeserializationInput.kt:98)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.des(DeserializationInput.kt:80)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.deserialize(DeserializationInput.kt:96)
    at net.corda.nodeapi.internal.serialization.amqp.AbstractAMQPSerializationScheme.deserialize(AMQPSerializationScheme.kt:123)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1$1.invoke(SerializationScheme.kt:111)
    at net.corda.core.serialization.SerializationFactory.withCurrentContext(SerializationAPI.kt:66)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:111)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:86)
    at net.corda.core.serialization.SerializationFactory.asCurrent(SerializationAPI.kt:80)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl.deserialize(SerializationScheme.kt:111)
    at net.corda.core.transactions.TraversableTransaction$outputs$1.invoke(MerkleTransaction.kt:356)
    at net.corda.core.transactions.TraversableTransaction$outputs$1.invoke(MerkleTransaction.kt:18)
    at net.corda.core.transactions.TraversableTransaction.deserialiseComponentGroup(MerkleTransaction.kt:66)
    at net.corda.core.transactions.TraversableTransaction.<init>(MerkleTransaction.kt:25)
    at net.corda.core.transactions.WireTransaction.<init>(WireTransaction.kt:43)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
    at net.corda.nodeapi.internal.serialization.amqp.ObjectSerializer.construct(ObjectSerializer.kt:138)
    at net.corda.nodeapi.internal.serialization.amqp.ObjectSerializer.readObjectBuildViaConstructor(ObjectSerializer.kt:97)
    at net.corda.nodeapi.internal.serialization.amqp.ObjectSerializer.readObject(ObjectSerializer.kt:82)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObject$node_api(DeserializationInput.kt:135)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObjectOrNull$node_api(DeserializationInput.kt:109)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.readObjectOrNull$node_api$default(DeserializationInput.kt:108)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput$deserialize$1.invoke(DeserializationInput.kt:98)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.des(DeserializationInput.kt:80)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.deserialize(DeserializationInput.kt:96)
    at net.corda.nodeapi.internal.serialization.amqp.AbstractAMQPSerializationScheme.deserialize(AMQPSerializationScheme.kt:123)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1$1.invoke(SerializationScheme.kt:111)
    at net.corda.core.serialization.SerializationFactory.withCurrentContext(SerializationAPI.kt:66)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:111)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:86)
    at net.corda.core.serialization.SerializationFactory.asCurrent(SerializationAPI.kt:80)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl.deserialize(SerializationScheme.kt:111)
    at net.corda.core.transactions.SignedTransaction.getCoreTransaction(SignedTransaction.kt:272)
    at net.corda.core.transactions.SignedTransaction.getInputs(SignedTransaction.kt:71)
    at net.corda.node.services.transactions.ValidatingNotaryFlow.receiveTransaction(ValidatingNotaryFlow.kt:50)
    at net.corda.node.services.transactions.ValidatingNotaryFlow.receiveAndVerifyTx(ValidatingNotaryFlow.kt:30)
    at net.corda.core.flows.NotaryFlow$Service.call(NotaryFlow.kt:142)
    at net.corda.core.flows.NotaryFlow$Service.call(NotaryFlow.kt:133)
    at net.corda.node.services.statemachine.FlowStateMachineImpl.run(FlowStateMachineImpl.kt:96)
    at net.corda.node.services.statemachine.FlowStateMachineImpl.run(FlowStateMachineImpl.kt:44)
    at co.paralleluniverse.fibers.Fiber.run1(Fiber.java:1092)
    at co.paralleluniverse.fibers.Fiber.exec(Fiber.java:788)
    at co.paralleluniverse.fibers.RunnableFiberTask.doExec(RunnableFiberTask.java:100)
    at co.paralleluniverse.fibers.RunnableFiberTask.run(RunnableFiberTask.java:91)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at net.corda.node.utilities.AffinityExecutor$ServiceAffinityExecutor$1$thread$1.run(AffinityExecutor.kt:62)

    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.des(DeserializationInput.kt:84)
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.deserialize(DeserializationInput.kt:96)
    at net.corda.nodeapi.internal.serialization.amqp.AbstractAMQPSerializationScheme.deserialize(AMQPSerializationScheme.kt:123)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1$1.invoke(SerializationScheme.kt:111)
    at net.corda.core.serialization.SerializationFactory.withCurrentContext(SerializationAPI.kt:66)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:111)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:86)
    at net.corda.core.serialization.SerializationFactory.asCurrent(SerializationAPI.kt:80)
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl.deserialize(SerializationScheme.kt:111)
    at net.corda.core.transactions.TraversableTransaction$outputs$1.invoke(MerkleTransaction.kt:356)
    at net.corda.core.transactions.TraversableTransaction$outputs$1.invoke(MerkleTransaction.kt:18)
    at net.corda.core.transactions.TraversableTransaction.deserialiseComponentGroup(MerkleTransaction.kt:66)
    ... 41 more

    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.des(DeserializationInput.kt:84) ~[corda-node-api-3.1-corda.jar:?]
    at net.corda.nodeapi.internal.serialization.amqp.DeserializationInput.deserialize(DeserializationInput.kt:96) ~[corda-node-api-3.1-corda.jar:?]
    at net.corda.nodeapi.internal.serialization.amqp.AbstractAMQPSerializationScheme.deserialize(AMQPSerializationScheme.kt:123) ~[corda-node-api-3.1-corda.jar:?]
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1$1.invoke(SerializationScheme.kt:111) ~[corda-node-api-3.1-corda.jar:?]
    at net.corda.core.serialization.SerializationFactory.withCurrentContext(SerializationAPI.kt:66) ~[corda-core-3.1-corda.jar:?]
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:111) ~[corda-node-api-3.1-corda.jar:?]
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl$deserialize$1.invoke(SerializationScheme.kt:86) ~[corda-node-api-3.1-corda.jar:?]
    at net.corda.core.serialization.SerializationFactory.asCurrent(SerializationAPI.kt:80) ~[corda-core-3.1-corda.jar:?]
    at net.corda.nodeapi.internal.serialization.SerializationFactoryImpl.deserialize(SerializationScheme.kt:111) ~[corda-node-api-3.1-corda.jar:?]
    at net.corda.core.transactions.SignedTransaction.getCoreTransaction(SignedTransaction.kt:272) ~[corda-core-3.1-corda.jar:?]
    at net.corda.core.transactions.SignedTransaction.getInputs(SignedTransaction.kt:71) ~[corda-core-3.1-corda.jar:?]
    at net.corda.node.services.transactions.ValidatingNotaryFlow.receiveTransaction(ValidatingNotaryFlow.kt:50) ~[corda-node-3.1-corda.jar:?]
    at net.corda.node.services.transactions.ValidatingNotaryFlow.receiveAndVerifyTx(ValidatingNotaryFlow.kt:30) ~[corda-node-3.1-corda.jar:?]
    at net.corda.core.flows.NotaryFlow$Service.call(NotaryFlow.kt:142) ~[corda-core-3.1-corda.jar:?]
    at net.corda.core.flows.NotaryFlow$Service.call(NotaryFlow.kt:133) ~[corda-core-3.1-corda.jar:?]
    at net.corda.node.services.statemachine.FlowStateMachineImpl.run(FlowStateMachineImpl.kt:96) [corda-node-3.1-corda.jar:?]
    at net.corda.node.services.statemachine.FlowStateMachineImpl.run(FlowStateMachineImpl.kt:44) [corda-node-3.1-corda.jar:?]
    at co.paralleluniverse.fibers.Fiber.run1(Fiber.java:1092) [quasar-core-0.7.9-jdk8.jar:0.7.9]
    at co.paralleluniverse.fibers.Fiber.exec(Fiber.java:788) [quasar-core-0.7.9-jdk8.jar:0.7.9]
    at co.paralleluniverse.fibers.RunnableFiberTask.doExec(RunnableFiberTask.java:100) [quasar-core-0.7.9-jdk8.jar:0.7.9]
    at co.paralleluniverse.fibers.RunnableFiberTask.run(RunnableFiberTask.java:91) [quasar-core-0.7.9-jdk8.jar:0.7.9]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_172]
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_172]
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_172]
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:1.8.0_172]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_172]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_172]
    at net.corda.node.utilities.AffinityExecutor$ServiceAffinityExecutor$1$thread$1.run(AffinityExecutor.kt:62) [corda-node-3.1-corda.jar:?]

对这个例外及其可能的起源有任何想法吗?

注意:对于未通过验证的公证人,似乎不会出现此问题。

1 个答案:

答案 0 :(得分:0)

这可能是因为验证公证人的类路径中没有包含MyClass的JAR。从Corda 3开始,您需要将其安装在公证人上,就像将其安装在常规节点上一样。