Uploaded image for project: 'Corda'
  1. CORDA-1663

Node won't start if cordapps generate states prior to deletion

    Details

    • Type: Bug
    • Status: Done (View workflow)
    • Priority: High
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: Corda 3.3
    • Component/s: None
    • Labels:
      None

      Description

      Have a cordapp installed in a node (used obligation cordapp). Used the app to create a bunch of states in the vault. Decided that I no longer wanted that app so I removed it. This lead to node not able to start due to a check of vault states against installed cordapps.

      Proposal: catch exception and log as warning to allow the node to start.

      Database connection url is              : jdbc:h2:tcp://localhost:11022/node
      Advertised P2P messaging addresses      : localhost:10022
      RPC connection address                  : localhost:10023
      RPC admin connection address            : localhost:1124
      [ERROR] 13:18:49+0100 [main] internal.Node.run - Exception during node startup
       java.lang.ClassNotFoundException: net.corda.examples.obligation.Obligation
      	at java.net.URLClassLoader.findClass(URLClassLoader.java:381) ~[?:1.8.0_144]
      	at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[?:1.8.0_144]
      	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:335) ~[?:1.8.0_144]
      	at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:1.8.0_144]
      	at java.lang.Class.forName0(Native Method) ~[?:1.8.0_144]
      	at java.lang.Class.forName(Class.java:264) ~[?:1.8.0_144]
      	at net.corda.node.services.vault.NodeVaultService.bootstrapContractStateTypes(NodeVaultService.kt:533) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.services.vault.NodeVaultService.<init>(NodeVaultService.kt:395) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode.makeVaultService(AbstractNode.kt:985) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode$ServiceHubInternalImpl$vaultService$2.invoke(AbstractNode.kt:1025) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode$ServiceHubInternalImpl$vaultService$2.invoke(AbstractNode.kt:1004) ~[corda-node-3.0.0-RC06.jar:?]
      	at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:74) ~[kotlin-stdlib-1.2.50.jar:1.2.50-release-103 (1.2.50)]
      	at net.corda.node.internal.AbstractNode$ServiceHubInternalImpl.getVaultService(AbstractNode.kt) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode.makeServices(AbstractNode.kt:786) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode.access$makeServices(AbstractNode.kt:160) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode$start$6.invoke(AbstractNode.kt:335) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode$start$6.invoke(AbstractNode.kt:160) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.nodeapi.internal.persistence.CordaPersistence.inTopLevelTransaction(CordaPersistence.kt:173) ~[corda-node-api-3.0.0-RC06.jar:?]
      	at net.corda.nodeapi.internal.persistence.CordaPersistence.transaction(CordaPersistence.kt:158) ~[corda-node-api-3.0.0-RC06.jar:?]
      	at net.corda.nodeapi.internal.persistence.CordaPersistence.transaction(CordaPersistence.kt:136) ~[corda-node-api-3.0.0-RC06.jar:?]
      	at net.corda.nodeapi.internal.persistence.CordaPersistence.transaction(CordaPersistence.kt:142) ~[corda-node-api-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.AbstractNode.start(AbstractNode.kt:322) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.Node.start(Node.kt:400) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.EnterpriseNode.start(EnterpriseNode.kt:170) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.NodeStartup.startNode(NodeStartup.kt:191) ~[corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.internal.NodeStartup.run(NodeStartup.kt:148) [corda-node-3.0.0-RC06.jar:?]
      	at net.corda.node.Corda.main(Corda.kt:25) [corda-node-3.0.0-RC06.jar:?]
      

        Attachments

          Activity

            People

            • Assignee:
              removed86 Former user (Inactive)
              Reporter:
              Bogdan.Paunescu Bogdan Paunescu
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: