Author: stliu
Date: 2009-11-14 08:18:39 -0500 (Sat, 14 Nov 2009)
New Revision: 17982
Modified:
annotations/branches/v3_4_0_GA_CP/src/java/org/hibernate/type/SerializableToBlobType.java
Log:
JBPAPP-2277 HHH-2990 - Bad usage of ClassLoader.loadClass() for Java6 in
SerializationHelper - deserialization bottleneck for arrays
Modified:
annotations/branches/v3_4_0_GA_CP/src/java/org/hibernate/type/SerializableToBlobType.java
===================================================================
---
annotations/branches/v3_4_0_GA_CP/src/java/org/hibernate/type/SerializableToBlobType.java 2009-11-14
12:56:08 UTC (rev 17981)
+++
annotations/branches/v3_4_0_GA_CP/src/java/org/hibernate/type/SerializableToBlobType.java 2009-11-14
13:18:39 UTC (rev 17982)
@@ -65,8 +65,8 @@
return SerializationHelper.serialize( (Serializable) object );
}
- private static Object fromBytes(byte[] bytes) throws SerializationException {
- return SerializationHelper.deserialize( bytes );
+ private Object fromBytes(byte[] bytes) throws SerializationException {
+ return SerializationHelper.deserialize( bytes, getReturnedClass().getClassLoader() );
}
public void set(PreparedStatement st, Object value, int index, SessionImplementor
session) throws SQLException {