Re: [Informa-developer] Problem with MySQL/Hibernate
Status: Beta
Brought to you by:
niko_schmuck
From: Aleksey G. <spy...@no...> - 2005-05-05 17:25:07
|
Hi Jakub, This issue was already raised on the list in the past. Here's what I wrote: --- By the way, the problem with deserialization exception (see "Re: [Informa-developer] Hibernate lazy initialization exception" thread started by Nick Groupinets) was related to the serialized links of items. The problem was that in database items' links appeared as empty strings (not NULL's) and consequentially could not be deserialized into valid java.net.URL objects on loading. It's not quite clear how they got into database yet. If you have any info on this please let the developers know. --- Hope it will help. Aleksey Gureev BlogBridge Team http://www.blogbridge.com/ On Thu, 2005-05-05 at 15:24 +0200, Jakub Hozak wrote: > Greetings > > I am using MySQL as a backend for Hibernate (Informa) and > testing really simple function. It just grabs some channel, > saves it by using the PersistenceManager and does the very > same thing it's items (using poller and PersistenceObserver). > And it works. BUT ... when I try to load the channel using > following hibernate code (I am a hibernate newbie ... correct > me if I am doing performing kind of stupidity here) > > try { > SessionHandler handler = SessionHandler.getInstance(); > Session session = handler.getSession(); > channel = (ChannelIF) session.load(Channel.class, id); > session.close(); > } catch (HibernateException he) { > logger.warn("Failed to load channel with ID " + id); > throw he; > } > > it dies with following error message: > > 4859 [main] DEBUG net.sf.hibernate.impl.SessionFactoryObjectFactory - > initializing class SessionFactoryObjectFactory > 4875 [main] DEBUG net.sf.hibernate.impl.SessionFactoryObjectFactory - > registered: 8a80809b03ad05a70103ad05aea50000 (unnamed) |