<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>Musings of a Trained Monkey: Tag spring</title>
    <link>http://www.stevelongdo.com/articles/tag/spring</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description></description>
    <item>
      <title>Code Generation STILL in Action</title>
      <description>&lt;p&gt;&lt;strong&gt;&lt;del&gt;&amp;#8212;&lt;/del&gt; The Past &lt;del&gt;&amp;#8212;&lt;/del&gt;&lt;/strong&gt;&lt;/p&gt;


	&lt;p&gt;Jack Herrington wrote a book &lt;a href="http://www.manning.com/herrington/"&gt;Code Generation in Action&lt;/a&gt; way back in 2003.  It took advantage of the little programming language that could, &lt;a href="http://ruby-lang.org"&gt;Ruby&lt;/a&gt;.  I remember having a discussion with a colleague back then about the value of generated code.  We were of the opinion then that it would only apply to simple repetitive cases and wouldn&amp;#8217;t make much of an impact.&lt;/p&gt;


	&lt;p&gt;If only I could go back in time and slap both myself and my colleague in the face!   We missed out on being early adopters of time saving technology.  In fact almost everyone using Java was already taking advantage of code generation whether they realized it or not , Eclipse would generate getters and setters and had its refactoring capabilities, &lt;a href="http://springframework.org"&gt;Spring&lt;/a&gt; was beginning to handle externalizing dependencies, and the then fledgling &lt;a href="http://hibernate.org"&gt;Hibernate Framework&lt;/a&gt; was manipulating bytecode to enhance  Java methods.&lt;/p&gt;


	&lt;p&gt;At the same time my colleague and I were hammering out code with the tried and true &lt;em&gt;cut-n-rape&lt;/em&gt; technique that had been popular since before we were born.&lt;/p&gt;


	&lt;p&gt;&lt;strong&gt;&lt;del&gt;&amp;#8212;&lt;/del&gt; Modern Day &lt;del&gt;&amp;#8212;&lt;/del&gt;&lt;/strong&gt;&lt;/p&gt;


	&lt;p&gt;I have the &lt;strong&gt;&amp;#8220;opportunity&amp;#8221;&lt;/strong&gt; to work on porting some old JSPs which, in true 20&lt;sup&gt;th&lt;/sup&gt; century Model 1 style, link directly to each other and the database via scriptlets, to a more modern Java &lt;span class="caps"&gt;MVC&lt;/span&gt; framework.  Rather than just wade in blindly, manually translating &lt;span class="caps"&gt;JSP&lt;/span&gt; scriptlet page to Java &lt;span class="caps"&gt;MVC&lt;/span&gt; framework code, I decided to make the project interesting and have been writing a &lt;a href="http://ruby-lang.org"&gt;Ruby&lt;/a&gt; JSP parser/code generator. It can identify scriptlet code and extract it for me. I have been enhancing the parser to handle generation of &lt;a href="http://springframework.org"&gt;Spring &lt;span class="caps"&gt;MVC&lt;/span&gt;&lt;/a&gt; code and am working on having it generate &lt;a href="http://www.springframework.org/webflow"&gt;Spring Web Flow&lt;/a&gt; flows from reading the form action attributes in the JSPs to model application flows.&lt;/p&gt;


	&lt;p&gt;&lt;a href="http://video.google.com/videoplay?docid=1541014406319673545&amp;#38;hl=en"&gt;Here is a 2006 appearance by Jack Herrington at Google on the subject of Code Generation that is worth a watch.&lt;/a&gt;&lt;/p&gt;</description>
      <pubDate>Sat, 17 Feb 2007 15:30:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:5b9cec95-f18e-46d9-8296-2c26cfdc6210</guid>
      <author>Steve Longdo</author>
      <link>http://www.stevelongdo.com/articles/2007/02/17/code-generation-still-in-action</link>
      <category>java</category>
      <category>ruby</category>
      <category>code</category>
      <category>spring</category>
    </item>
    <item>
      <title>Spring now in 3D</title>
      <description>&lt;p&gt;I have resisted posting anything about the &lt;a href="http://www.thespringexperience.com/show_view.jsp?showId=45"&gt;Spring Experience 2006&lt;/a&gt; until now.  Mostly because postings on my blog have been Ruby-centric or me-centric, but let&amp;#8217;s break the embargo for a post or two.&lt;/p&gt;


	&lt;p&gt;The opening keynote by &lt;a href="http://www.interface21.com/people/rod.html"&gt;Rod Johnson&lt;/a&gt; was a loser.  He started out by checking his bank balance and then doing a UK patent search to demonstrate that some websites in the world use Spring under the covers!  &lt;strong&gt;Duh&lt;/strong&gt;!&lt;br /&gt;&lt;br /&gt;  While &lt;a href="http://www.interface21.com/people/rod.html"&gt;Rod&lt;/a&gt; was dumbing it down for those in attendance, a table at the back of the room featuring some of the conference speakers as well as a baby, began to reminisce about other conferences they&amp;#8217;ve gotten money for and such.  They were loud enough it was hard to hear the keynote.  This was especially rude because the speakers are only there to present because people like me (well my company) paid &lt;em&gt;money&lt;/em&gt; for them to be there.  Glad you guys enjoy being around each other, but take it out in the hall next time with the baby if you want to be loud.&lt;br /&gt;&lt;br /&gt;
Also I think some limited mockery of &lt;a href="http://domaindrivendesign.org/books/index.html"&gt;Domain Driven Design&lt;/a&gt; is called for.  People need to stop making up &lt;strong&gt;?DD&lt;/strong&gt; acronyms.  I&amp;#8217;m all for having a software methodology and following its doctrines when they make sense, but you just know some idiot somewhere is going to post about how  &lt;em&gt;This &lt;span class="caps"&gt;JEE&lt;/span&gt; Web 2.0 website , is now brought to you in 3D!&lt;/em&gt;. 
&lt;br /&gt;&lt;br /&gt;
The Spring guys seem to have bitten into this D&lt;sup&gt;3&lt;/sup&gt; stuff hook, line, and sinker.  Martin Fowler blessed the &lt;a href="http://domaindrivendesign.org/books/index.html"&gt;book&lt;/a&gt; with his own brand of stink so it must be good right?  There was a dedicated D&lt;sup&gt;3&lt;/sup&gt; track available at the conference on the topic.   I can&amp;#8217;t figure out why there wasn&amp;#8217;t enough Spring content to fill out that track as well.  It was the &lt;a href="http://www.thespringexperience.com/show_view.jsp?showId=45"&gt;Spring Experience&lt;/a&gt; after all!
&lt;br /&gt;&lt;br /&gt;
Anyway there was some good content presented, &lt;a href="http://raibledesigns.com/page/rd/20061208"&gt;Matt Raible&lt;/a&gt; did a great job writing it up for the Java faithful.  I&amp;#8217;ll leave my non-mocking commentary on the conference some other time.&lt;/p&gt;</description>
      <pubDate>Tue, 12 Dec 2006 01:50:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:57dd9928-9c68-4873-98d4-d45c84d91291</guid>
      <author>Steve Longdo</author>
      <link>http://www.stevelongdo.com/articles/2006/12/12/spring-now-in-3d</link>
      <category>java</category>
      <category>spring</category>
    </item>
    <item>
      <title>Java, Spring and Why I Haven't Posted Lately...</title>
      <description>Things have been busy on the work side of my activities lately.  Work is currently revolving around Java and using &lt;a href="http://springframework.org"&gt;Spring&lt;/a&gt; MVC.  Since I have primarily focused on Ruby and &lt;a href="http://www.rubyonrails.org"&gt;Rails&lt;/a&gt; information on my blog, I've been reluctant to blog about where my head is at in the Java space. If someone is interested, leave a comment and I'll see what I can come up with.&lt;br /&gt;&lt;br /&gt;
Which isn't to say I am not tracking recent developments in the &lt;a href="http://www.rubyonrails.org"&gt;Rails&lt;/a&gt; community, just that I haven't had time to analyze their impact and vomit forth a blog entry or two :-)&lt;br /&gt;&lt;br /&gt;
Okay, one little morsel of my experience with &lt;a href="http://springframework.org"&gt;Spring&lt;/a&gt; relates to one of the core tenets of &lt;a href="http://www.rubyonrails.org"&gt;Rails&lt;/a&gt;: &lt;a href="http://static.springframework.org/spring/docs/2.0.x/reference/mvc.html#mvc-coc"&gt;"Convention over configuration"&lt;/a&gt;. &lt;br /&gt;It finally found a way into a Java web development framework!</description>
      <pubDate>Fri, 06 Oct 2006 03:37:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:ea5f146d-7a7b-4385-8550-dd94f56a73ad</guid>
      <author>Steve Longdo</author>
      <link>http://www.stevelongdo.com/articles/2006/10/06/java-spring-and-why-i-havent-posted-lately</link>
      <category>rails</category>
      <category>spring</category>
      <category>java</category>
    </item>
    <item>
      <title>Tomcat 5.5/Java 5 and SSL...</title>
      <description>I ran into a puzzling situation trying to setup &lt;a href="https://clearinghouse.ja-sig.org/wiki/display/CAS/Home"&gt;Yale's CAS&lt;/a&gt; and the &lt;a href="http://www.springframework.org/"&gt;Spring Framework&lt;/a&gt;/&lt;a href="http://acegisecurity.sourceforge.net"&gt;Acegi &lt;/a&gt; contacts sample application on my workstation.  I had CAS deployed on &lt;a href="http://tomcat.apache.org/"&gt;Tomcat 5.5&lt;/a&gt; and the &lt;a href="http://acegisecurity.sourceforge.net/"&gt;Acegi&lt;/a&gt; sample application deployed on &lt;a href="http://www.bea.com/framework.jsp?CNT=index.htm&amp;FP=/content/products/weblogic"&gt;BEA WebLogic 9.0&lt;/a&gt;, both running under &lt;a href="http://java.sun.com"&gt;Sun's JDK 1.5.0_06&lt;/a&gt;.  I kept getting errors like:&lt;div style="overflow: auto;"&gt;&lt;typocode&gt;&lt;pre&gt;Your CAS credentials were rejected.&lt;br/&gt;
Reason: HTTPS hostname wrong: &amp;lt;localhost&gt; should be &lt;127.0.0.1&gt;&lt;/pre&gt;&lt;/typocode&gt;&lt;/div&gt;
I couldn't figure this out because the &lt;typocode&gt;server.xml&lt;/typocode&gt; for &lt;a href="http://tomcat.apache.org/"&gt;Tomcat&lt;/a&gt; included both the &lt;typocode&gt;keystoreFile&lt;/typocode&gt; and &lt;typocode&gt;truststoreFile&lt;/typocode&gt; parameters for the SSL connection.  The JVM JRE cacerts file included self-signed certs for both the &lt;a href="http://www.bea.com/framework.jsp?CNT=index.htm&amp;FP=/content/products/weblogic"&gt;BEA &lt;/a&gt; server and the &lt;a href="http://tomcat.apache.org/"&gt;Tomcat&lt;/a&gt; server which should be picked up system wide whether or not I specifically include it in the &lt;typocode&gt;server.xml&lt;/typocode&gt; file.  I am not sure why but putting the following option on the &lt;a href="http://tomcat.apache.org/"&gt;Tomcat&lt;/a&gt; command line solved the problem:&lt;br/&gt;&lt;div style="overflow: auto; "&gt;&lt;typocode&gt;&lt;pre&gt;-Djavax.net.ssl.trustStore="C:\Program Files\Java\jre1.5.0_06\lib\security\cacerts"&lt;/pre&gt;&lt;/typocode&gt;
&lt;/div&gt;You can also see from this that it is a Windows workstation...  I am documenting this for the benefit of other programmers and Google (which doesn't have much of anything about this particular problem).
</description>
      <pubDate>Mon, 12 Dec 2005 20:30:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:29735744-1a78-4ba9-a691-45d15917f441</guid>
      <author>Steve Longdo</author>
      <link>http://www.stevelongdo.com/articles/2005/12/12/tomcat-5-5-java-5-and-ssl</link>
      <category>java</category>
      <category>tomcat</category>
      <category>bea</category>
      <category>spring</category>
      <category>acegi</category>
      <trackback:ping>http://www.stevelongdo.com/articles/trackback/34</trackback:ping>
    </item>
  </channel>
</rss>
