comparison src/org/dancres/blitz/txn/TxnManager.java @ 17:4580bb12db30

Separate command execution from command logging.
author Dan Creswell <dan.creswell@gmail.com>
date Sun, 05 Jul 2009 16:26:25 +0100
parents 3dc0c5604566
children
comparison
equal deleted inserted replaced
16:46ac1a45718a 17:4580bb12db30
127 theLogger.log(Level.INFO, "Doing log recovery..."); 127 theLogger.log(Level.INFO, "Doing log recovery...");
128 128
129 thePrevayler = myPersonality.getPrevayler(new TxnManagerState()); 129 thePrevayler = myPersonality.getPrevayler(new TxnManagerState());
130 130
131 theLogger.log(Level.INFO, "Log Recovery complete..."); 131 theLogger.log(Level.INFO, "Log Recovery complete...");
132 132 theLogger.log(Level.INFO, "Using prevayler: " + thePrevayler.getClass());
133
133 theManagerState = (TxnManagerState) thePrevayler.system(); 134 theManagerState = (TxnManagerState) thePrevayler.system();
134 135
135 theCheckpointTrigger = 136 theCheckpointTrigger =
136 myPersonality.getCheckpointTrigger(new CheckpointerImpl(this)); 137 myPersonality.getCheckpointTrigger(new CheckpointerImpl(this));
137 138
481 throws Exception { 482 throws Exception {
482 if (dontLog) { 483 if (dontLog) {
483 // System.err.println("Bypass"); 484 // System.err.println("Bypass");
484 return aCommand.execute(theManagerState); 485 return aCommand.execute(theManagerState);
485 } else { 486 } else {
486 // System.err.println("Full log"); 487 // System.err.println("Full log: " + thePrevayler.getClass());
487 return thePrevayler.executeCommand(aCommand); 488 return thePrevayler.executeCommand(aCommand);
488 } 489 }
489 } 490 }
490 491
491 /** 492 /**