Rainy days and Java always get me down

I've Moved My Blog

It's currently located at http://www.urlinone.com/blog

I should say "I'm moving my blog." It's a pretty painful process.

Pebble has blown up on me, and it's been many months since I've been able to blog reliably. I've lost posts. And now I've got to figure out how to migrate my past blog posts from Pebble to my new destination without all the URLs changing, lest external links become 404 Not Founds.

Why does everything in the 21st century have to be a three-day project???

These are the steps required to add a new library to your AppFuse project:

  1. Create a new directory under lib to hold your jars. For example, I created C:\projects\appfuseproj\lib\sonic-6.1.
  2. Copy your jar or jars into that directory. You can also create subdirectories under your new directory. For example, the lib\hibernate directory contains a lib subdirectory where jars that hibernate depends on are stored.
  3. Add a section in lib\lib.properties to hook your new jar(s) into the application, such as
    # Sonic - http://www.sonicsoftware.com
  4. Add your new jar(s) to your compile and test classpaths in properties.xml (in the root directory of your project), so that all your classes are resolvable at build time. There are a few ways you can do this, depending on how the new jars are organized in their directory. For example, I added several SonicMQ and Sonic ESB jars to the sonic-6.1 directory, so I added an ant fileset to the paths where they are needed:
    <!-- Service -->
    <path id="service.compile.classpath">
        <path refid="dao.compile.classpath"/>
        <pathelement location="${dist.dir}/${webapp.name}-dao.jar"/>
        <fileset dir="${javamail.dir}" includes="*.jar"/>
        <pathelement location="${commons-lang.jar}"/>
        <pathelement location="${commons-logging.jar}"/>
        <pathelement location="${commons-beanutils.jar}"/>
        <pathelement location="${commons-collections.jar}"/>
        <fileset dir="${sonic.dir}" includes="*.jar"/>
        <fileset dir="${spring.dir}" includes="*.jar"/>
        <fileset dir="${velocity.dir}" includes="*.jar"/>
    <path id="web.test.classpath">
        <path refid="web.compile.classpath"/>
        <pathelement location="${dumbster.jar}"/>
        <pathelement location="${junit.jar}"/>
        <pathelement location="${junitdoclet.jar}"/>
        <fileset dir="${webtest.dir}/lib" includes="*.jar"/>
        <pathelement location="${log4j.jar}"/>
        <fileset dir="${velocity.dir}" includes="*.jar"/>
        <fileset dir="${sonic.dir}" includes="*.jar"/>
        <!-- Needed for testing out-of-container -->
        <path refid="dao.compile.classpath"/>
    Notice that there are a couple of ways to reference your new jars, and you may use the .dir property or the .jar property. The pathelement and .jar property are for when you have a single jar to add to your classpath, but the fileset and .dir property work when you are adding a bunch of jars.

    Take special note of the hibernate classpath, because it can tell you how to construct a complex classpath that can be added to another classpath, for example:

    <!-- Hibernate -->
    <path id="hibernate.classpath">
        <pathelement location="${hibernate.jar}"/> 
        <fileset dir="${hibernate.dir}/lib" includes="*.jar"/>
        <pathelement location="${database.jar}"/> 
        <pathelement location="${commons-beanutils.jar}"/>
        <pathelement location="${commons-lang.jar}"/>
        <path location="${build.dir}/dao/classes"/>
    <!-- DAO -->
    <path id="dao.compile.classpath">
        <path refid="hibernate.classpath"/>
        <pathelement location="${commons-lang.jar}"/>
        <pathelement location="${commons-logging.jar}"/>
        <fileset dir="${spring.dir}" includes="*.jar"/>
    Here, the hibernate.classpath is constructed from pathelements, a fileset, and a path element. This multi-element path is then added to the dao.compile.classpath classpath using <path refid="hibernate.classpath"/>.
    (If you wish to do builds in Eclipse, you should add your new jars to your Eclipse build classpath, as well.)
  5. In the war target of build.xml (in the root directory of your project), you will need to add the jar(s) that you want deployed for runtime. I added the line
                <lib dir="${sonic.dir}" includes="*.jar"/>
    near the bottom of the list of lib elements within the war target. Remember that order in the classpath can sometimes be of significance, so place your new jars appropriately. If things start acting wiggy, that is something to look at.
    Also, take note of how the hibernate dependencies are included differently here from the way they were included in the classpath:
                <lib dir="${hibernate.dir}/lib">
                    <include name="odmg*.jar"/>
                    <include name="dom4j*.jar"/>
                    <include name="cglib*.jar"/>
                    <include name="ehcache*.jar"/>
                    <include name="oscache*.jar"/>
    With numerous or complex hierarchies of jars, you'll find using the hibernate structure as a guide can be helpful.

That should allow you to add any new custom or open source libraries to your AppFuse project. Have fun!

This is completely CSS, no graphics, which is very impressive.

But this is amazing!

(Both links open new windows.)

I only had to listen to it fifty times:

I feel like a freak
'Cause every time I pull out something to eat
For this week
I can’t do this
'Cause I’m Jewish, and
I can’t eat bread,
Yeah, my Rabbi said only Matzah.
Any way you want to eat it
Cold or hot it’s Matzah
Fun for your mother, brother, sister, father Matzah
Buy in bulk for a lower cost per box it’s Matzah
Matzah Matzah Matzah Matzah

Hanukkah, no that's over.
So you don’t passed over
Get your ass over to my pad, it’s Passover.
I’m the mad flow who’s heebie-jeebin’ with the jibbin’ jabbin’
If you want the story of Passover 
Rent The Ten Commandments starring Charlton Heston.

But I got a question 
‘bout the bread that is unleavened
Causing indigestion
Called Matzah
Eat it for a week we gotsta.
No bread, no pasta.
Best believe that you'll be stopped up!

Now Moses made the matzah when he was fleeing Egypt,
Had no time for bread to rise.
He said "Ah just leave it. We can eat it like this. Feed it to the Hebrews."
But little did he know that the week would end up equal
Let my people go
Became the anthem,
So get your damn hands up,
Maybe it will help you pass some.

How could one bread rocket so famous
When the taste is just the flavor of the box it came in?
Eat it at one single second guessin'.
Leaving crumbs on my lap and chest,
And it’s called Matzah!
I found the Afikomen!
In my small intestine.
Matzah Matzah Matzah Matzah

These lyrics are not-so-obviously copyright Eric Schwartz aka Smooth-E.

You can listen to Matzah at JibJab.

I don't know if Why the Lucky Stiff (the name alone causes me some trepidation) is truly criminal, but spend a few minutes at his (her?) (its?) web site and tell me that that's not the work of a madman (madwoman?) (madperson?).

Still, he/she/it has created why's (poignant) guide to Ruby, which seems almost coherent, despite the fact that by the third paragraph, he's (let's just assume it's a he) talking about housecoats. I've never learned a language from cartoon foxes before, but by chapter 3, they're already showing me code.

And by chapter 4, you've made your own starmonkey by plunging car keys into an apple.

Update: I've come to appreciate what a freakin' genius Why is. He's (yes, Why's a he) funny, smart, and incredibly prolific. His RedHanded blog is a great source for what's new in the world of Ruby, Rails, and general wackiness. I've become something of a groupie. This is one lunatic that's going places (and not necessarily in a straight jacket). I'll be able to say I knew Why when...