예제 #1
0
        internal void canCommit()
        {
            Console.WriteLine("I'm the participant: " + MY_URL);
            Console.WriteLine("Coordinator URL: " + _coordinatorURL);
            ICoordinator coord = (ICoordinator)Activator.GetObject(typeof(ICoordinator), _coordinatorURL);

            MY_DECISION = TransactionDecision.COMMIT;

            //  writeAheadLog();

            timer();
            coord.sendYes(TX.TXID, MY_URL);

            MY_DECISION = waitForCoordinator();
        }