Author: borges
Date: 2011-11-18 05:43:37 -0500 (Fri, 18 Nov 2011)
New Revision: 11698
Modified:
trunk/hornetq-core/src/main/java/org/hornetq/core/persistence/impl/journal/JournalStorageManager.java
Log:
throw correct Java exception.
Modified:
trunk/hornetq-core/src/main/java/org/hornetq/core/persistence/impl/journal/JournalStorageManager.java
===================================================================
---
trunk/hornetq-core/src/main/java/org/hornetq/core/persistence/impl/journal/JournalStorageManager.java 2011-11-18
10:43:18 UTC (rev 11697)
+++
trunk/hornetq-core/src/main/java/org/hornetq/core/persistence/impl/journal/JournalStorageManager.java 2011-11-18
10:43:37 UTC (rev 11698)
@@ -17,6 +17,7 @@
import java.io.PrintStream;
import java.nio.ByteBuffer;
import java.security.AccessController;
+import java.security.InvalidParameterException;
import java.security.PrivilegedAction;
import java.util.ArrayList;
import java.util.Arrays;
@@ -185,7 +186,7 @@
return MESSAGES;
if (BINDINGS.typeByte == type)
return BINDINGS;
- throw new RuntimeException("invalid byte");
+ throw new InvalidParameterException("invalid byte: " + type);
}
}