From 8c1544d1608b68f83044f3cf6fd059200197c2e6 Mon Sep 17 00:00:00 2001 From: djmil Date: Mon, 27 Nov 2023 16:16:12 +0100 Subject: [PATCH] 1 --- .../src/main/java/djmil/cordacheckers/gamestate/CommitTrx.java | 1 + .../java/djmil/cordacheckers/gamestate/CommitTrxResponder.java | 2 ++ 2 files changed, 3 insertions(+) diff --git a/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrx.java b/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrx.java index 7141c5e..e28adf5 100644 --- a/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrx.java +++ b/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrx.java @@ -52,6 +52,7 @@ public class CommitTrx implements SubFlow { @Suspendable public SecureHash call() { log.info("GameState commit started"); + System.out.println("Surrender commit started"); /* * Calls the Corda provided finalise() function which gather signatures from the counterparty, diff --git a/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrxResponder.java b/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrxResponder.java index f6b37be..ce9a576 100644 --- a/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrxResponder.java +++ b/corda/workflows/src/main/java/djmil/cordacheckers/gamestate/CommitTrxResponder.java @@ -57,12 +57,14 @@ public class CommitTrxResponder implements ResponderFlow { @Suspendable void checkParticipants(FlowSession session, UtxoLedgerTransaction gameStateUtxo) throws ParticipantException { + System.out.println("commit responder"); final GameInfo info = new GameInfo(gameStateUtxo); final var conterpartyName = session.getCounterparty(); if (info.issuer.compareTo(conterpartyName) != 0) throw new ParticipantException("Issuer", conterpartyName, info.issuer); final var myName = memberLookup.myInfo().getName(); + System.out.println(" my name" + myName + " opponentName "+ conterpartyName); if (myName.getOrganizationUnit().equals("Custodian")) return; // Custodian shall not validate state's counterparty