<?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>Yann's Blog &#187; Java</title>
	<atom:link href="http://yannramin.com/category/software/java/feed/" rel="self" type="application/rss+xml" />
	<link>http://yannramin.com</link>
	<description>Software and life</description>
	<lastBuildDate>Wed, 07 Jul 2010 20:04:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>gIRM Git Repository Available</title>
		<link>http://yannramin.com/2007/12/11/girm-git-repository-available/</link>
		<comments>http://yannramin.com/2007/12/11/girm-git-repository-available/#comments</comments>
		<pubDate>Wed, 12 Dec 2007 07:50:14 +0000</pubDate>
		<dc:creator>Yann</dc:creator>
				<category><![CDATA[Grails]]></category>
		<category><![CDATA[IRM 2]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[SCM]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://yannramin.com/2007/12/11/girm-git-repository-available/</guid>
		<description><![CDATA[In addition to trying out new Kool-aid with Groovy and Grails, I&#8217;ve decided to move from tracking in Subversion to tracking in Git the gIRM code base. The gitweb is available here: http://stackworks.net/cgi-bin/gitweb.cgi?p=girm.git;a=summary and cloning is available at git://stackworks.net/girm.git/]]></description>
			<content:encoded><![CDATA[<p>In addition to trying out new Kool-aid with Groovy and Grails, I&#8217;ve decided to move from tracking in Subversion to tracking in <a href="http://git.or.cz" title="Git">Git </a>the gIRM code base.</p>
<p>The gitweb is available here:<a href="http://stackworks.net/cgi-bin/gitweb.cgi?p=girm.git;a=summary" title="http://stackworks.net/cgi-bin/gitweb.cgi?p=girm.git;a=summary"> http://stackworks.net/cgi-bin/gitweb.cgi?p=girm.git;a=summary</a></p>
<p>and cloning is available at</p>
<p>git://stackworks.net/girm.git/</p>
]]></content:encoded>
			<wfw:commentRss>http://yannramin.com/2007/12/11/girm-git-repository-available/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Development insights from IRM 2 and other Java Web Projects</title>
		<link>http://yannramin.com/2007/11/30/development-insights-from-irm-2-and-other-java-web-projects/</link>
		<comments>http://yannramin.com/2007/11/30/development-insights-from-irm-2-and-other-java-web-projects/#comments</comments>
		<pubDate>Fri, 30 Nov 2007 08:22:46 +0000</pubDate>
		<dc:creator>Yann</dc:creator>
				<category><![CDATA[IRM 2]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://yannramin.com/2007/11/30/development-insights-from-irm-2-and-other-java-web-projects/</guid>
		<description><![CDATA[Its me again, and this time I bring news of lessons learned with the current development work on IRM 2. Firstly, while EJB 3.0 is miles better than EJB 2.1, it doesn&#8217;t match up to a proper IoC container. By IoC, I am talking both about the Tapestry 5 IoC container, and the Spring IoC [...]]]></description>
			<content:encoded><![CDATA[<p>Its me again, and this time I bring news of lessons learned with the current development work on IRM 2.</p>
<p>Firstly, <strong>while EJB 3.0 is miles better than EJB 2.1, it doesn&#8217;t match up to a proper IoC container</strong>. By IoC, I am talking both about the Tapestry 5 IoC container, and the Spring IoC container. I find that with writing service methods with EJB, I spend far too much time both massaging domain objects between the EJB layer and the Tapestry layer &#8211; the Hibernate/JPA session is no longer valid outside of the EJB layer, so forget about all the &#8220;cool&#8221; stuff it does, such as lazy fetching, and wallow in pain replicating that functionality.</p>
<p>Second, <strong>component based view models are powerful, but not quick to grasp</strong>. I grew up (shame shame) on PHP, doing in-line HTML output. I know, this is bad, and I know better. I&#8217;ve grown accustomed to other view technologies such as templates (Smarty, Cheetah-Template, Velocity, etc), but still find myself taking a long time developing a workable component based model. This may be a shortcoming in Tapestry, but its taken me far longer to develop views than I would like. I will say that the component model is stronger than JSPs, but sometimes quick &amp; dirty JSP gets you there faster. Some of this may be my experiences with Tapestry 5 talking, which I will discuss further below.</p>
<p>Third, <strong>Hibernate</strong> <strong>is amongst the best ORM wrappers available and a major time saver</strong>. Compared to other ORM wrappers out there (like ActiveRecord), it has an unmatched feature set, often backed by very mature Java technologies and libraries.</p>
<p><strong>Java is a good language, and a fantastic environment</strong>. Yes, the language isn&#8217;t that great &#8211; overly verbose, no closure, a little too static. But the Java libraries available, especially on the server-side are un-matched from other web-development languages, including my favorite language, Python.</p>
<p><strong>Groovy is a very promising language.</strong> Closures, duck-typing, first class JVM language, and more. Libraries that should have existed ages ago (XmlSlurper comes to mind). If you&#8217;re going to do quick development in a Java environment, or looking at a scripting solution in Java, give Groovy a strong look.</p>
<p>Whatever you do, <strong>avoid the creation of your own GWF</strong>. Also known as the Ghetto Web Framework. We&#8217;ve all seem them &#8211; you started out with some servlets, and went from there, making half-baked utility functions, some copy and pasting, etc. You get a maintenance nightmare &#8211; changes which should simply be a two-liner end up being propagated in odd places in your GWF, requiring exponential time to change. Plus your GWF is so tightly coupled to your application,  you can&#8217;t use it for the next application. There are so many web frameworks out there &#8211; please use one <img src='http://yannramin.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><strong>Groovy on Grails makes an incredible rapid development environment</strong>. Coupled with Groovy, and with idea taken from  Ruby on Rails amongst other systems, you get an incredible Java development environment which is more productive and quicker to develop in than EJB, Tapestry, and maybe even the venerable RoR. Plus, its pure Java nature coupled with libraries such as Hibernate and Spring, you gain all the advantages of scalability and support that you just don&#8217;t get in RoR.</p>
<p><strong>Wicket and Tapestry are very well organized frameworks.</strong> While I talked somewhat negatively about component based frameworks above, I would like to mention that both of these frameworks are fantastic in their own right. Wicket seems to be gaining a lot of momentum as well. But, on a negative note, <strong>Tapestry 5 needs more documentation</strong>. You can buy 200 books on Struts (though why you&#8217;d want to use it is beyond me), 3 on Grails, 1 (and soon 2) on Wicket, and 0 on Tapestry 5. Tapestry 5 really needs more developer momentum and support to come to fruition. Howard Lewis Ship is doing a fantastic job on being very careful and deliberate in his design and crafting of Tapestry, but he is after all one person, and can not do it all.</p>
<p>So, you may ask,  what does this have to do with IRM 2?</p>
<p>Well, I&#8217;ve been once again at the crank. I&#8217;ve realized that the code I wanted to avoid writing (simple CRUD), I am writing again, primarily through my mis-choice of EJB3. Partly contributing to this is Tapestry -  I&#8217;m writing a fair number of CRUD views &#8211; none of which are in any way exciting.</p>
<p>I&#8217;ve been converting the existing code from Tapestry/EJB to the Groovy on Grails framework.  Its been amazing easy to accomplish, and the Grails scaffolding support has been an amazing productivity boost.</p>
<p>Look for a developer&#8217;s release by the end of the year .</p>
<p>Till then</p>
<p>-Yann</p>
]]></content:encoded>
			<wfw:commentRss>http://yannramin.com/2007/11/30/development-insights-from-irm-2-and-other-java-web-projects/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Tapestry 5: Rendering a Block in a page</title>
		<link>http://yannramin.com/2007/04/12/tapestry-5-rendering-a-block-in-a-page/</link>
		<comments>http://yannramin.com/2007/04/12/tapestry-5-rendering-a-block-in-a-page/#comments</comments>
		<pubDate>Fri, 13 Apr 2007 03:59:00 +0000</pubDate>
		<dc:creator>Yann</dc:creator>
				<category><![CDATA[IRM 2]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://yannramin.com/2007/04/12/tapestry-5-rendering-a-block-in-a-page/</guid>
		<description><![CDATA[This one took awhile to figure out. In Tapestry, if a component is passed to another component (such as your main page layout component), you need to pass it as a Block parameter. The problem with blocks, there is no quick way to render them. You can use the @AfterRenderBody rendering stage annotation, but this [...]]]></description>
			<content:encoded><![CDATA[<p>This one took awhile to figure out. In Tapestry, if a component is passed to another component (such as your main page layout component), you need to pass it as a Block parameter. The problem with blocks, there is no quick way to render them. You can use the @AfterRenderBody rendering stage annotation, but this gives you very limited flexibility in where the object will end up (or you make kludgy hacks to put this together). </p>
<p>This quick little component can solve all those problems. I present you Render.java. This incredible class is appearing in IRM 2.</p>
<p><b>Update</b>: You can also use the builtin Tapestry component named Delegate.</p>
<pre><code>&lt;t:delegate to="block:foo"/&gt;</code></pre>
<p>But if you still prefer, you can use this Component:</p>
<pre>
<code>
package net.stackworks.irm.web.components;
import org.apache.tapestry.annotations.Parameter;
</code>

<code>
/**
 * Simple component which will render a Block in a page.
 * To use: - Make sure your Block has a defined getter method (getSidebar()) which returns the Block
 *         - Do a &lt;t:render value="sidebar"/&gt; &lt;!-- this calls getSidebar() --&gt;
 *         - Enjoy your rendered Block
 * @author Yann Ramin
 *
 */
public class Render {
	@Parameter(required = true)
	private Object _value;

	/**
	 * Returns the Object, which allows another object (presumably, a block) to render
	 * first.
	 *
	 * @return Object to render
	 */
	Object beginRender() {
		return _value;
	}
}
</code>
</pre>
<p><!--adsense--></p>
]]></content:encoded>
			<wfw:commentRss>http://yannramin.com/2007/04/12/tapestry-5-rendering-a-block-in-a-page/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Work on IRM 2 Progresses, Web Framework, and Logo</title>
		<link>http://yannramin.com/2007/04/11/work-on-irm-2-progresses/</link>
		<comments>http://yannramin.com/2007/04/11/work-on-irm-2-progresses/#comments</comments>
		<pubDate>Thu, 12 Apr 2007 07:35:28 +0000</pubDate>
		<dc:creator>Yann</dc:creator>
				<category><![CDATA[IRM 2]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://yannramin.com/2007/04/11/work-on-irm-2-progresses/</guid>
		<description><![CDATA[Just a quick update that yes, indeed, work is continuing. I have a full Tapestry 5 based web framework, which currently supports abstract templating and other functionality with Tapestry components. I also have a full Tapestry-&#62;EJB3.0 call system developed (just need to actually go write the Beans now ), and have started mapping the data [...]]]></description>
			<content:encoded><![CDATA[<p>Just a quick update that yes, indeed, work is continuing.</p>
<p>I have a full <a href="http://tapestry.apache.org/tapestry5/">Tapestry 5</a> based web framework, which currently supports abstract templating and other functionality with Tapestry components. I also have a full Tapestry-&gt;EJB3.0 call system developed (just need to actually go write the Beans now <img src='http://yannramin.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ), and have started mapping the data model for Users, CRI (Cross Reference Identifier, the new name of the IRM2Python GUID, more on this later), and Schemas.</p>
<p>One tricky part is developing the <a href="http://java.sun.com/products/jaas/">JAAS</a> authentication scheme. I&#8217;m working through some substitutes, but also expect to support non-JAAS simple database authentication (at least for now).</p>
<p>I also had a chance to do a little work in Illustrator on the visual front, developing a new logo for IRM2. See below for an idea of what it looks like. Its designed to emphasize the connected nature of IRM, from the trouble tickets to the AssetMesh. Feel free to leave comments.</p>
<p>More later!</p>
<p><a href="http://yannramin.com/wp-content/uploads/2007/04/irm2idea2.png" title="irm2idea2.png"><img src="http://yannramin.com/wp-content/uploads/2007/04/irm2idea2.png" alt="irm2idea2.png" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://yannramin.com/2007/04/11/work-on-irm-2-progresses/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Announcing IRM 2, MkIII</title>
		<link>http://yannramin.com/2007/04/03/announcing-irm-2-mkiii/</link>
		<comments>http://yannramin.com/2007/04/03/announcing-irm-2-mkiii/#comments</comments>
		<pubDate>Wed, 04 Apr 2007 00:13:24 +0000</pubDate>
		<dc:creator>Yann</dc:creator>
				<category><![CDATA[IRM 2]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://yannramin.com/archives/8</guid>
		<description><![CDATA[I&#8217;ve done a lot of thinking, some non-thinking, talking to people, users, and some (well ok, a lot) of prototyping. As a result of all that work, I have decided to revive and continue to work on a new IRM 2, the re-architectured Information Resource Manager application. New features, new code base, but same target, [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve done a lot of thinking, some non-thinking, talking to people, users, and some (well ok, a lot) of prototyping. As a result of all that work, I have decided to <strong><em>revive and continue to work on a new IRM 2</em></strong>, the re-architectured Information Resource Manager application. New features, new code base, but same target, <em>you</em>, the dedicated IRM users.</p>
<p>I&#8217;ll get into all the details of what IRM 2 is going to do for you, but I&#8217;d first like to share some history with you about where IRM has come from, the previous short attempts at IRM 2, and how its influenced my current direction.</p>
<blockquote><p>In the beginning was the command line.</p>
<p>Then  came IRM. It was quite literally the second piece of software I wrote as a web application. It used the trendy new (well at the time) PHP 3.0. MySQL 3.22 was the in thing. The whole LAMP architecture was just in its infancy.IRM was created way back when (1999 for those keeping score) for my high school. It allowed people to post problems (using the odd nomenclature &#8220;Tracking&#8221;) about computers that were in its database. The database seed script that comes with IRM reflects these early beginnings, including the computer named Ants and the Library Back Room.IRM went through several versions, 0.5, 0.9, 0.9b, 0.9c, etc. Around the 1.0 release, a really great guy from the <a href="http://www.utulsa.edu/">University of Tuls</a><a href="http://www.utulsa.edu/">a</a> , Keith Schoenefeld  started contributing to IRM. He cleaned up a ton of my early major misguided attempts at software development (turns out ENDIF; is kinda not cool), and over time provided new functionality such as the FAQ and Knowledgebase system.</p>
<p>IRM grew in leaps and bounds, adding the Software subsystem, the Reports subsystem, and then Networking. Patch submissions from Mica Curie also started, and some key features were added to the project.<br />
In 2004-2005 another contributer joined the project, Matt Palmer. Not only did he make a nice <a href="http://packages.debian.org/unstable/web/irm">Debian package</a> for IRM (<em>apt-get install irm</em> is so much easier <img src='http://yannramin.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ), he allowed for the full translation of the IRM source. Version 1.4 and then 1.5 were released under his guidance. By that time I had started full time at <a href="http://ucdavis.edu">UC Davis</a>, so my time was becoming slim catching up with all those college things. Matt graciously took up the maintainer role for IRM 1.5 and released several versions, culminating in 1.5.8-dev, the current recommended version (or 1.5.7 for the squeemish).</p>
<p>During all of those time, I became increasingly dissatisfied with the PHP structure that IRM was running on.  Its underpinnings were still dating back from 1999, PHP 3.0 code, strange code reuse, no abstract templating, and a fixed database structure. In 2002 I attempted a partial rewrite of IRM called IRT (Information Resource <em>Tracker</em>) in a custom <a href="http://perl.apache.org/">mod_perl</a> framework (the job I had at the time was developing a custom mod_perl application for <a href="http://www.footagesearch.com/">footagesearch.com</a> &#8211; still used to this day, though its had numerous updates). It failed miserably. I can&#8217;t even find the source code.</p>
<p>Next up was <a href="http://stackworks.net/irm2">IRM 2.0 in Python</a>. It included some new ideas for abstract schemas and relational linking. Its asset manager actually worked. It was developed in a custom Python application server <a href="http://stackworks.net/cymbeline">Cymbeline</a>, which was probably a bad move as I was spending more time developing Cymbeline than IRM 2. This also fell by the wayside during those college years. But it was a great learning exercise in what worked and what didn&#8217;t.</p>
<p>And thats the history in a summary. If you were a contributor (I know I left a bunch out, especially when I was not active maintainer <img src='http://yannramin.com/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> ), let me know and I&#8217;ll add you to the history <img src='http://yannramin.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Since working on IRM, my life has changed a lot. I graduated high school (yes, IRM is <em>that</em> old), graduated college, and got a good &#8220;real job.&#8221; More importantly, I&#8217;ve built lots of <em>real</em> software in between, for personal use, research work, as well as commercial contract work. I&#8217;ve been around the block a few times, and tried on a large number of hats, all of which will reflect themselves in the design and implementation of IRM 2.</p></blockquote>
<p><a title="features" name="features"></a><br />
So, that gives us IRM 2, Mk III. The third incarnation of IRM2. And better, more powerful, and very different from the rest. Read on.</p>
<p>To begin, its still a web application. IRM is never going to be solely a desktop application, though the line between web application and desktop application is really blurring these days.</p>
<p>It utilizes <a href="http://java.sun.com">Java</a>.  I can already hear the complaints trickling in. I&#8217;ve grown quite fond of Java at my day job, and really recognized what strengths it brings to the enterprise web application front. The Sun Java VM is now also <a href="http://opensource.org">Open Source,</a> with the rest of the classpath libraries becoming Open Source in the near future. There are multiple Java vendors, and Java does really run everywhere these days. Java is also very quick, and the framework provided with it are top-notch. A considerably worse choice would be to move to .NET and ASP.NET.</p>
<p>It utilizes <a href="http://java.sun.com/products/ejb/">Enterprise JavaBeans 3.0</a> . These are not the EJBs of 2.0 and 1.0 days, which were, to put it mildly, horrible. EJB3.0 is actually a joy to work with, and brings with it an amazing amount of functionality, such as transactional support, security, and scalability.</p>
<p>It utilizes the <a href="http://java.sun.com/javaee/overview/faq/persistence.jsp">Java Persistence API 1.0</a>, along with <a href="http://hibernate.org">Hibernate</a> when the JPA doesn&#8217;t go far enough. Both of these technologies are wonderful to use, and greatly speed development (and makes maintenance much easier).</p>
<p>For the presentation layer, <a href="http://tapestry.apache.org/">Apache Tapestry</a> won out over other packages such as Struts2, JSF, and Spring. While I prefer to use Java Community standards whenever possible, I compromised for Tapestry as it is a wonderful (though not well known) package.</p>
<p>All of this can successfully run in the <a href="http://jboss.org">JBoss Application Server</a>, making deployment a snap on any platform.  It can also be run in any mostly-EJB3.0 compliant container, though drop-in portability will not be a focus of the first releases. By utilizing Java Persistence, we will automatically support any JDBC compliant database server, from good old <a href="http://mysql.com">MySQL</a>, Oracle, PostgreSQL, Microsoft SQL, DB2, to the built in <a href="http://hsqldb.org/">HSQLDB</a>.</p>
<p>I am working on a master roadmap which lays out our development cycles and sets goals. Look here in the next few days for updates on how its going to look.</p>
<p>In short, IRM 2 will feature:</p>
<ul>
<li>The asset manager interface from PythonIRM2. User definable schemas for any device, item, location, or thought you can think of. Fully linkable schemas let you associate users, software, locations, peripherals, and potted plants together into an AssetMesh<sup>tm</sup>. Since everything is associated in real life, why not let your asset manager let you express that?</li>
<li>Trouble ticket system to manage user problems, your own problems, and let you keep your head on straight. Includes both user ticketing, technician ticketing, and phone support ticketing.</li>
<li>User self help system, bringing back the FAQ, user trouble reporting, and other features which made IRM into such a successful integrated application for the IT helpdesk.</li>
<li>And more!</li>
</ul>
<p>To bright futures ahead, but remembering the beginnings&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://yannramin.com/2007/04/03/announcing-irm-2-mkiii/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

<!-- Dynamic Page Served (once) in 0.302 seconds -->
