From: <phr...@im...> - 2002-12-18 18:24:08
|
hi, it seems to be some sort of class-loading issue - the PrimaryKey class that the generator returns, and the one that the bean uses seems to have been loaded by a different classloader, so even though they are the same class, they are not compatible. have someone encountered the same issue? is there a way i can make hibernate use the same classloader? best regards, viktor On Tue, 17 Dec 2002 09:24:23 +1100, "Gavin King" <Gav...@ex...> said: > Why don't you try stepping through code. Put a break point in > > AbstractEntityPersister.setIdentifier() > > and see exactly what class of object is passed in. (This should > definately all work as advertised.) > > > > > > > cirrus.hibernate.PropertyAccessException: IllegalArgumentException > > > occurred while calling setter of test.hibernate.Foo.pk at > > > cirrus.hibernate.helpers.ReflectHelper.set(ReflectHelper.java:190) > > > at > > > > > cirrus.hibernate.persister.AbstractEntityPersister.setIdentifier(Abstr > > > actEntityPersister.java:281) > > > at cirrus.hibernate.impl.SessionImpl.doSave(SessionImpl.java:528) > > > at cirrus.hibernate.impl.SessionImpl.save(SessionImpl.java:483) > > > at > > cirrus.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java:919) > > > at > > > > > test.hibernate.ejb.HibTestSessionBean.saveFoo(HibTestSessionBe > > an.java:53) > > > > -- phr...@im... -- http://fastmail.fm - Consolidate POP email and Hotmail in one place |