diff --git a/.idea/runConfigurations/BankOfCordaDriverKt___Issue_Web.xml b/.idea/runConfigurations/BankOfCordaDriverKt___Issue_Web.xml new file mode 100644 index 0000000000..321d3d2d06 --- /dev/null +++ b/.idea/runConfigurations/BankOfCordaDriverKt___Issue_Web.xml @@ -0,0 +1,15 @@ + + + + + \ No newline at end of file diff --git a/.idea/runConfigurations/BankOfCordaDriverKt___Run_Stack.xml b/.idea/runConfigurations/BankOfCordaDriverKt___Run_Stack.xml new file mode 100644 index 0000000000..ea61b6ef8d --- /dev/null +++ b/.idea/runConfigurations/BankOfCordaDriverKt___Run_Stack.xml @@ -0,0 +1,15 @@ + + + + + \ No newline at end of file diff --git a/samples/bank-of-corda-demo/src/main/kotlin/net/corda/bank/BankOfCordaDriver.kt b/samples/bank-of-corda-demo/src/main/kotlin/net/corda/bank/BankOfCordaDriver.kt index b24a49b33a..b526e580fe 100644 --- a/samples/bank-of-corda-demo/src/main/kotlin/net/corda/bank/BankOfCordaDriver.kt +++ b/samples/bank-of-corda-demo/src/main/kotlin/net/corda/bank/BankOfCordaDriver.kt @@ -5,6 +5,7 @@ import net.corda.bank.api.BankOfCordaClientApi import net.corda.bank.api.BankOfCordaWebApi.IssueRequestParams import net.corda.core.identity.CordaX500Name import net.corda.core.utilities.NetworkHostAndPort +import net.corda.finance.flows.CashConfigDataFlow import net.corda.finance.flows.CashExitFlow import net.corda.finance.flows.CashIssueAndPaymentFlow import net.corda.finance.flows.CashPaymentFlow @@ -57,23 +58,28 @@ private class BankOfCordaDriver { when (role) { Role.ISSUER -> { driver(dsl = { + startNotaryNode(providedName = DUMMY_NOTARY.name, validating = true) val bankUser = User( BANK_USERNAME, "test", permissions = setOf( + startFlowPermission(), + startFlowPermission(), + startFlowPermission(), startFlowPermission(), - startFlowPermission())) - val bigCorpUser = User(BIGCORP_USERNAME, "test", - permissions = setOf( - startFlowPermission())) - startNotaryNode(DUMMY_NOTARY.name, validating = true) + startFlowPermission() + )) val bankOfCorda = startNode( providedName = BOC.name, rpcUsers = listOf(bankUser)) + val bigCorpUser = User(BIGCORP_USERNAME, "test", + permissions = setOf( + startFlowPermission(), + startFlowPermission())) startNode(providedName = BIGCORP_LEGAL_NAME, rpcUsers = listOf(bigCorpUser)) startWebserver(bankOfCorda.get()) waitForAllNodesToFinish() - }, isDebug = true) + }, isDebug = true, extraCordappPackagesToScan = listOf("net.corda.finance.contracts.asset")) } else -> { val requestParams = IssueRequestParams(options.valueOf(quantity), options.valueOf(currency), BIGCORP_LEGAL_NAME, @@ -81,12 +87,12 @@ private class BankOfCordaDriver { when(role) { Role.ISSUE_CASH_RPC -> { println("Requesting Cash via RPC ...") - val result = BankOfCordaClientApi(NetworkHostAndPort("localhost", 10006)).requestRPCIssue(requestParams) + val result = BankOfCordaClientApi(NetworkHostAndPort("localhost", 10004)).requestRPCIssue(requestParams) println("Success!! You transaction receipt is ${result.tx.id}") } Role.ISSUE_CASH_WEB -> { println("Requesting Cash via Web ...") - val result = BankOfCordaClientApi(NetworkHostAndPort("localhost", 10007)).requestWebIssue(requestParams) + val result = BankOfCordaClientApi(NetworkHostAndPort("localhost", 10005)).requestWebIssue(requestParams) if (result) println("Successfully processed Cash Issue request") } diff --git a/testing/node-driver/src/main/kotlin/net/corda/testing/driver/Driver.kt b/testing/node-driver/src/main/kotlin/net/corda/testing/driver/Driver.kt index d6733b1576..ff8bdc3e14 100644 --- a/testing/node-driver/src/main/kotlin/net/corda/testing/driver/Driver.kt +++ b/testing/node-driver/src/main/kotlin/net/corda/testing/driver/Driver.kt @@ -961,7 +961,7 @@ class DriverDSL( maximumHeapSize: String ): CordaFuture { val processFuture = executorService.fork { - log.info("Starting out-of-process Node ${nodeConf.myLegalName.organisation}") + log.info("Starting out-of-process Node ${nodeConf.myLegalName.organisation}, debug port is " + debugPort ?: "not enabled") // Write node.conf writeConfig(nodeConf.baseDirectory, "node.conf", config)