<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>CodeDependents &#187; classpath</title>
	<atom:link href="http://codedependents.com/tag/classpath/feed/" rel="self" type="application/rss+xml" />
	<link>http://codedependents.com</link>
	<description>Two Geeks Walk Into A Blog</description>
	<lastBuildDate>Mon, 30 Apr 2012 15:53:40 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='codedependents.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>CodeDependents &#187; classpath</title>
		<link>http://codedependents.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://codedependents.com/osd.xml" title="CodeDependents" />
	<atom:link rel='hub' href='http://codedependents.com/?pushpress=hub'/>
		<item>
		<title>Integrate ant with dbdeploy not in the classpath</title>
		<link>http://codedependents.com/2009/01/26/integrate-ant-with-dbdeploy-not-in-the-classpath/</link>
		<comments>http://codedependents.com/2009/01/26/integrate-ant-with-dbdeploy-not-in-the-classpath/#comments</comments>
		<pubDate>Mon, 26 Jan 2009 22:47:37 +0000</pubDate>
		<dc:creator>Benjamin Darfler</dc:creator>
				<category><![CDATA[Software Engineering]]></category>
		<category><![CDATA[ant]]></category>
		<category><![CDATA[classpath]]></category>
		<category><![CDATA[dbdeploy]]></category>
		<category><![CDATA[ivy]]></category>
		<category><![CDATA[taskdef]]></category>

		<guid isPermaLink="false">http://blog.bdarfler.com/?p=132</guid>
		<description><![CDATA[The need for a schema versioning system at LocaModa finally became a priority this sprint so I&#8217;ve spent the past few days researching and diving into implementation.  After comparing LiquiBase, dbdeploy, MIGRATEdb, and dbmigrate I settled on the simple SQL driven solution that dbdeploy provides and started integrating it with our Ant build.  Pramod Sadalage over at Agile DBA put [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=codedependents.com&#038;blog=7973493&#038;post=132&#038;subd=codedependents&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-136" style="margin-right:5px;" title="Frustration" src="http://bdarfler.files.wordpress.com/2009/01/rsz_frustration.jpg?w=630" alt="Frustration"   />The need for a schema versioning system at <a href="http://www.locamoda.com">LocaModa</a> finally became a priority this sprint so I&#8217;ve spent the past few days researching and diving into implementation.  After comparing <a href="http://www.liquibase.org/">LiquiBase</a>, <a href="http://dbdeploy.com/">dbdeploy</a>, <a href="http://migratedb.sourceforge.net/">MIGRATEdb</a>, and <a href="http://code.google.com/p/dbmigrate/">dbmigrate</a> I settled on the simple SQL driven solution that dbdeploy provides and started integrating it with our <a href="http://ant.apache.org/">Ant</a> build.  <span class="given-name"><a href="http://www.linkedin.com/in/pramodsadalage">Pramod</a></span><a href="http://www.linkedin.com/in/pramodsadalage"> </a><span class="family-name"><a href="http://www.linkedin.com/in/pramodsadalage">Sadalage</a> over at <a href="http://www.sadalage.com/">Agile DBA</a> put up a <a href="http://www.sadalage.com/2008/01/exprerience_using_dbdeploy_on_1.html">nice post</a> on the basics but I quickly hit a wall, the <a href="http://www.mysql.com/">MySQL</a> driver was not in my classpath.</span></p>
<p><span class="family-name">As I</span><span class="family-name"><a href="http://blog.bdarfler.com/2008/11/11/pimpin-your-ant-build-with-ivy/"> mentioned earlier</a> we are using <a href="http://ant.apache.org/ivy/">Ivy</a> for our dependancy management which makes it difficult to throw jars into the Ant classpath since they are automatically downloaded at build time.  So far this hasn&#8217;t been an issue since most Ant tasks allow you to specify the classpath as a parameter within the task.  Dbdeploy does not.  Goggling around I quickly found <a href="http://groups.google.com/group/db-deploy-users/browse_thread/thread/a381c9cc3c8e0d9f/050ace04ddaf7519">a posting</a> that suggested patching the dbdeploy ant task as the only way to go, so off I went.  However, a few hours later, after wandering through the Java classloader abyss I was stymied.</span></p>
<p><span class="family-name">I backed out of the changes and decided a different tactic was needed; back to Goggle I went.  This time I came across <a href="http://marc.info/?t=112482713500002&amp;r=1&amp;w=2">a post</a> which suggested all I needed was to add the jar to the taskdef classpath  Could it really be that easy?  Switching back to my build.xml I doctored up the dbdeploy taskdef, kicked off a build and sure enough the damn thing worked.</span></p>
<p><span class="family-name">So, if you want to centrally manage your ant dependencies, just remember to add the necessary classpath references to your taskdefs, like so:</span></p>
<p><code><span class="family-name">&lt;taskdef name="dbdeploy"</span><br />
<span class="family-name">        classname="net.sf.dbdeploy.AntTarget"</span><br />
<span class="family-name">        classpath="${dbdeploy.jar}:${mysql-connector.jar}"/&gt;</span></code></p>
<p><span class="family-name"><a class="DiggThisButton DiggMedium" href="http://digg.com/submit?url=http%3A%2F%2Fcodedependents.com%2F2009%2F01%2F26%2Fintegrate-ant-with-dbdeploy-not-in-the-classpath%2F&amp;title=Integrate+ant+with+dbdeploy+not+in+the%26nbsp%3Bclasspath"></a><br />
</span></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/codedependents.wordpress.com/132/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/codedependents.wordpress.com/132/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/codedependents.wordpress.com/132/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/codedependents.wordpress.com/132/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/codedependents.wordpress.com/132/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/codedependents.wordpress.com/132/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/codedependents.wordpress.com/132/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/codedependents.wordpress.com/132/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/codedependents.wordpress.com/132/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/codedependents.wordpress.com/132/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/codedependents.wordpress.com/132/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/codedependents.wordpress.com/132/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/codedependents.wordpress.com/132/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/codedependents.wordpress.com/132/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=codedependents.com&#038;blog=7973493&#038;post=132&#038;subd=codedependents&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://codedependents.com/2009/01/26/integrate-ant-with-dbdeploy-not-in-the-classpath/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e0132e931569bbd7d6ad6ef56a6f11db?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">bdarfler</media:title>
		</media:content>

		<media:content url="http://bdarfler.files.wordpress.com/2009/01/rsz_frustration.jpg" medium="image">
			<media:title type="html">Frustration</media:title>
		</media:content>
	</item>
	</channel>
</rss>
