When performing domain saving and retrieving in different sessions (in order to avoid Hibernate use session's cache) java.lang.ClassCastException: Cannot cast [Ljava.lang.Double; to [Ljava.lang.Float exception is thrown for domains having property of type Float[].
That happens because PostgreSQL stores such property in column of type float8[] and JDBC maps it to Double instead of Float.
Maybe remove Floats support at all?
Please check also http://docs.oracle.com/javase/1.5.0/docs/guide/jdbc/getstart/mapping.html#1055162
When performing domain saving and retrieving in different sessions (in order to avoid Hibernate use session's cache)
java.lang.ClassCastException: Cannot cast [Ljava.lang.Double; to [Ljava.lang.Float
exception is thrown for domains having property of typeFloat[]
. That happens because PostgreSQL stores such property in column of typefloat8[]
and JDBC maps it toDouble
instead ofFloat
. Maybe remove Floats support at all? Please check also http://docs.oracle.com/javase/1.5.0/docs/guide/jdbc/getstart/mapping.html#1055162