Author: borges
Date: 2011-07-07 06:48:36 -0400 (Thu, 07 Jul 2011)
New Revision: 10946
Modified:
branches/HORNETQ-720_Replication/hornetq-journal/src/main/java/org/hornetq/core/journal/impl/JournalImpl.java
Log:
Remove duplicated code.
Modified:
branches/HORNETQ-720_Replication/hornetq-journal/src/main/java/org/hornetq/core/journal/impl/JournalImpl.java
===================================================================
---
branches/HORNETQ-720_Replication/hornetq-journal/src/main/java/org/hornetq/core/journal/impl/JournalImpl.java 2011-07-07
10:22:56 UTC (rev 10945)
+++
branches/HORNETQ-720_Replication/hornetq-journal/src/main/java/org/hornetq/core/journal/impl/JournalImpl.java 2011-07-07
10:48:36 UTC (rev 10946)
@@ -2876,19 +2876,16 @@
}
/**
- *
- * @param completeTransaction If the appendRecord is for a prepare or commit, where we
should update the number of pendingTransactions on the current file
- * */
+ * @param completeTransaction If the appendRecord is for a prepare or commit, where we
should
+ * update the number of pendingTransactions on the current file
+ */
private JournalFile appendRecord(final JournalInternalRecord encoder,
final boolean completeTransaction,
final boolean sync,
final JournalTransaction tx,
final IOAsyncTask parameterCallback) throws
Exception
{
- if (state != JournalState.LOADED)
- {
- throw new IllegalStateException("The journal is not loaded " +
state);
- }
+ checkJournalIsLoaded();
final IOAsyncTask callback;
Show replies by date