<?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/"
	>

<channel>
	<title>Javatech &#187; Application Servers</title>
	<atom:link href="http://javatech.org/category/application-servers/feed/" rel="self" type="application/rss+xml" />
	<link>http://javatech.org</link>
	<description>The Bleeding Edge of Java Technology</description>
	<lastBuildDate>Wed, 24 Jun 2009 22:30:48 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Discovering Roo</title>
		<link>http://javatech.org/2009/06/discovering-roo/</link>
		<comments>http://javatech.org/2009/06/discovering-roo/#comments</comments>
		<pubDate>Sun, 14 Jun 2009 20:51:49 +0000</pubDate>
		<dc:creator>deevis</dc:creator>
				<category><![CDATA[Application Servers]]></category>
		<category><![CDATA[Architecture]]></category>
		<category><![CDATA[Spring]]></category>
		<category><![CDATA[Web Frameworks]]></category>
		<category><![CDATA[aspectj]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[roo]]></category>

		<guid isPermaLink="false">http://javatech.org/?p=77</guid>
		<description><![CDATA[I decided to follow along with the presentation given by Ben Alex during the SpringOne Keynote Address by Rod Johnson.
First &#8211; I have to install Roo and get the Roo shell up and running.  I&#8217;m really excited at this point because Roo does look really cool &#8211; really RAD!
So I download Roo and explode it [...]]]></description>
			<content:encoded><![CDATA[<p>I decided to follow along with the presentation given by Ben Alex during the <a title="SpringOne Keynote Address by Rod Johnson" href="http://www.infoq.com/presentations/SpringOne-Keynote-Rod-Johnson" target="_self">SpringOne Keynote Address by Rod Johnson</a>.</p>
<p>First &#8211; I have to install Roo and get the Roo shell up and running.  I&#8217;m really excited at this point because Roo does look really cool &#8211; really RAD!</p>
<p>So I <a title="Download Roo 1.0.0.M1" href="http://s3.amazonaws.com/dist.springframework.org/milestone/ROO/spring-roo-1.0.0.M1.zip" target="_self">download Roo</a> and explode it out to where I explode all of my 3rd party tools and then open <a title="cygwin" href="http://www.cygwin.com/">cygwin</a> (I&#8217;m on Windows and am trying hard to move away from Dos&#8230;) and navigate to the new directory.  I find a bin directory with two scripts in it: roo.bat and roo.sh.  Sweet!  They have a linux version ( cygwin == linux in many ways ).  So I run roo.sh and get:</p>
<p><strong>./roo.sh</strong></p>
<pre style="border: 1px inset; margin: 0px; padding: 6px; overflow: auto; width: 800px; height: 204px; text-align: left;" dir="ltr">Exception in thread "main" java.lang.NoClassDefFoundError: org/springframework/roo/bootstrap/Bootstrap
Caused by: java.lang.ClassNotFoundException: org.springframework.roo.bootstrap.Bootstrap
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
Could not find the main class: org.springframework.roo.bootstrap.Bootstrap.  Program will exit.</pre>
<p>OK &#8211; take a step back.  What have I done wrong here.</p>
<p>I back up a directory and also try <strong>./bin/roo.sh</strong>.  I look in the readme.txt and create the symlink for install on linux that they recommend:</p>
<p><strong>ln -s /path/to/roo/bin/roo.sh /usr/bin/roo</strong></p>
<p>I type in &#8216;roo&#8217; and get the same BootStrap Exception.</p>
<p>So then I invoke the wisdom of Google and learn that most everyone who encounters this error gets it because they are in Dos and are working in a different drive than where Roo is installed.  I&#8217;m on the same drive &#8211; but it&#8217;s not working in cygwin!  No hits on this somehow?!?  I find some other results which want me to additionally set an environment variable ROO_HOME.  I do this by running from the Roo install directory ( above bin, that is&#8230;):</p>
<p><strong>export ROO_HOME=`pwd`</strong></p>
<p><strong>env | grep ROO</strong></p>
<p>I still get the same problem (ClassNotFoundException: org.springframework.roo.bootstrap.Bootstrap), so I cave and go into a Dos prompt.  Well, first I add %ROO_HOME%\bin to my path, and *then* go into a Dos prompt.  I run &#8216;roo&#8217; and get the same Bootstrap Exception again.  But now, I am on the wrong drive, and cd to the same drive I installed Roo on &#8211; now things are working.</p>
<p>Time to even start using Roo in this example : <strong>15 minutes</strong></p>
<p>So, Roo is working now &#8211; I have a shell up and running.  I&#8217;m stoked because it really is cool.  It has &#8216;hint&#8217; as a keyword and tab-based auto-completion which is contextual &#8211; it auto-completes the correct things at the correct times.<br />
<a title="Creating a Project with Roo" href="http://javatech.org/article_yet_to_be_written">Creating a project with Roo</a> is a very nice experience : <strong>3 minutes</strong></p>
<p>I already have maven2 installed so I&#8217;m able to exit out of Roo and run &#8216;mvn eclipse:eclipse&#8217; and import the project into Eclipse : <strong>2 minute</strong>s</p>
<p>Wow, now we&#8217;re flying.  Except, wait, there a bunch of &#8220;.aj&#8221; files in my project.  Cool, <a title="Spring Roo Leverages AspectJ" href="http://javatech.org/article_yet_to_be_written">Roo is leveraging AspectJ</a>.  Suck, I don&#8217;t have AJDT plugin configured for Eclipse and I&#8217;m missing a bunch of the stuff Roo has added to my project ( 9 .aj files in all ).  Thinking this might not matter, I run the JUnitTest that Roo created for my project and see only 1 test being run &#8211; the demo has a bunch of tests being run ( added via AspectJ ).  Also, when I auto-complete on my entity class I created, I don&#8217;t get any of the framework added static methods.  Translation: I need to install the AJDT plugin for Eclipse: <strong>10 minutes</strong> ( http://download.eclipse.org/tools/ajdt/34/update ).</p>
<p>Now things are good to go &#8211; I now see the out-of-the box static methods added to my domain class ( Choice.java ).   And now when I run the JUnitTest I see that 8 new tests have been added and run.  But there&#8217;s something else stinky in the state of Denmark!</p>
<pre style="border: 1px inset; margin: 0px; padding: 6px; overflow: auto; width: 800px; height: 40px; text-align: left;" dir="ltr">IllegalStateException: Entity manager has not been injected (is the Spring Aspects JAR configured as an AJC/AJDT aspects library?</pre>
<p>No, the SpringAspects JAR is *NOT* configured as an AJC/AJDT aspects library!  I don&#8217;t know what the SpringAspects JAR is nor what it means to configure it as an AJC/AJDT aspects library.  Basically, this means you need to select the spring-aspects.jar to be in the Aspect Path of the AspectJ Build configuration of the project.  A picture is worth a 1,000 words here</p>
<div id="attachment_84" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-84" title="aspectj_spring_aspects_configuration" src="http://javatech.org/wp-content/uploads/2009/06/aspectj_spring_aspects_configuration-300x170.jpg" alt="Adding spring-aspects.jar to AspectJ Build path" width="300" height="170" /><p class="wp-caption-text">Adding spring-aspects.jar to AspectJ Build path</p></div>
<p><strong>10 minutes</strong></p>
<p>So, we&#8217;re up to 40 minutes of time spent when the whole thing up until now should only be 5 minutes.</p>
<p>But wait, there&#8217;s more.  Now I find that I don&#8217;t have setters being woven into my Choice.java class by the Choice_Roo_Javabean.aj aspect.  I see the correct code in the aspect, but Eclipse&#8217;s autocomplete and the actual compilation fail when I attempt to access new Choice().setNamingChoice().    I can deal with this later because I&#8217;ve got to get on with the demo.</p>
<p>Next up &#8211; Roo will automatically update the companion aspect files it creates as new properties are added to the domain entity.  That is, if I simply add a new property called &#8216;description&#8217; to my entity, and I have roo running in the background, then the Choice_Roo_Javabean.aj is automatically updated with the new getter/setter methods, and the Choice_Roo_ToString.aj is updated to include description.  SUPER COOL.</p>
<p>On a tangent, it is not mandatory that these woven aspects dictate the toString and javabean parts of the entity class.  The class has annotations in it to specify that the framework will handle these concerns: @RooJavaBean, @RooToString.  There is also a @RooEntity which adds all of the dao-ish methods to the class.  This is a pattern taken from Grails.</p>
<p>At this point we have an autogenerated JavaBean and a companion TestCase that works.</p>
<p>What about the webapp?  Inside of Roo shell, we can now run:</p>
<p><strong>new controller automatic</strong></p>
<p>With a few arguments to generate the framework jsps, the wiring, the formBackingObject functionality and even the crud forms for the domain entity.  The ordering of the fields on the crud forms matches the order in which they appear in the java file.  Changing the order of properties in the java file will change their order in the ToString.aj and crud JSPs as well. <strong>2 minutes</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://javatech.org/2009/06/discovering-roo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Server Side &#8211; Application Server Matrix</title>
		<link>http://javatech.org/2007/10/server-side-application-server-matrix/</link>
		<comments>http://javatech.org/2007/10/server-side-application-server-matrix/#comments</comments>
		<pubDate>Sun, 28 Oct 2007 15:45:35 +0000</pubDate>
		<dc:creator>deevis</dc:creator>
				<category><![CDATA[Application Servers]]></category>

		<guid isPermaLink="false">http://javatech.org/?p=11</guid>
		<description><![CDATA[The ServerSide  has put together a great listing of all the J2EE Application Server solutions that are available ( both free and for cost ) in their Application Server Matrix.  It&#8217;s nice to have such a comprehensive list of offerings and I learned that if you want to use EJB3, then it looks like JBoss [...]]]></description>
			<content:encoded><![CDATA[<p>The <a href="http://www.theserverside.com/" title="ServerSide">ServerSide</a>  has put together a great listing of all the J2EE Application Server solutions that are available ( both free and for cost ) in their <a href="http://www.theserverside.com/tt/articles/article.tss?l=ServerMatrix" title="Application Server Matrix">Application Server Matrix</a>.  It&#8217;s nice to have such a comprehensive list of offerings and I learned that if you want to use EJB3, then it looks like JBoss or Glassfish for you.</p>
]]></content:encoded>
			<wfw:commentRss>http://javatech.org/2007/10/server-side-application-server-matrix/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
