Now, this is interesting, isn't it (my emphasis in bold)?
Mar 08 14:59:11 DEBUG [main] impl.SessionImpl - collection fully initialized: [org.blojsom.blog.database.DatabaseBlogEntry._metaData#8381756bfb2c0eaf00fb2c0eb1760001]
Mar 08 14:59:11 DEBUG [main] impl.SessionImpl - 1 collections initialized
Mar 08 14:59:11 DEBUG [main] impl.SessionImpl - collection initialized
Mar 08 14:59:11 DEBUG [main] servlet.BlojsomServlet - 8381756bfb2c0eaf00fb2c0eb1760001
Mar 08 14:59:11 DEBUG [main] servlet.BlojsomServlet - Loaded id: 8381756bfb2c0eaf00fb2c0eb1760001
Mar 08 14:59:11 DEBUG [main] servlet.BlojsomServlet - Loaded title: Title 1
Mar 08 14:59:11 DEBUG [main] servlet.BlojsomServlet - stuff2=STRING/java.lang.String
Mar 08 14:59:11 DEBUG [main] servlet.BlojsomServlet - stuff1=1/java.lang.Integer
Mar 08 14:59:11 DEBUG [main] servlet.BlojsomServlet - stuff3=Mon Mar 08 14:59:11 EST 2004/java.util.Date
At the mo', my current method for mapping a HashMap in Hibernate is as follows. Hibernate experts, if there's a better way to get a HashMap with an arbitrary set of object types in it into the database, by all means, let me know.
<map name="_metaData" table="BlogEntryMetadata" access="field">
<key column="BLOG_ENTRY_METADATA_KEY"/>
<index column="BLOG_ENTRY_METADATA_INDEX" type="serializable"/>
<element column="BLOG_ENTRY_METADATA_ELEMENT" type="serializable"/>
</map>
Life is good. So, let me leave you with some wisdom.
I know you're out there...I can feel you now. I know that you're afraid. You're afraid of us, you're afraid of change...I don't know the future...I didn't come here to tell you how this is going to end, I came here to tell you how this is going to begin. Now, I'm going to hang up this phone, and I'm going to show these people what you don't want them to see. I'm going to show them a world without you...a world without rules and controls, without borders or boundaries. A world...where anything is possible.
<cue-music band="Rage Against The Machine" song="Wake Up"/>