question: public void beginTransaction ( ) throws IOException { if ( inTransaction ) throw new IllegalStateException ( "You can't start a transaction twice. this: " + this ) ; inTransaction = true ; lastTransactionInsertId = committedNextRowId - 1 ; synchronized ( this ) { rwRaf . setLength ( HEADER_SIZE + recordSize * committedNextRowId ) ; } insertRecordOut = new BufferedOutputStream ( insertRecordFileOut = new FileOutputStream ( filename , true ) ) ; rollForwardOut = new BufferedOutputStream ( rollForwardFileOut = new FileOutputStream ( getRollForwardFile ( true ) ) ) ; writeRollForwardHeader ( ) ; }
target:  Only one thread is allowed to begin a transaction.