Coulda woulda shoulda - Grails for PHP developers

Date January 11, 2008

I had considered submitting a codemash proposal about “Grails for PHP developers”.  I was counseled out of this by a certain someone as it was considered “too niche”.  I probably could have renamed it “Grails for non-Java developers”, and submitted it.  I think I will do that next year (or keep the PHP tag in there), because I think it’s needed.  I think this is a talk I will work on and prepare for OSCON and anyone else who will have me.

I went to two sessions - one Groovy and one Grails - and while both were good, neither, in my view, did a very good job of explaining some of the Java concepts at play to non-Java people.  Also, issues of app hosting for public projects would be huge, especially for PHP devs who are used to every host in the world supporting PHP left, front and center.  For some examples:

It was mentioned that “Grails uses Spring by default”.  What “Spring” is was not discussed at all - what does it provide, what are its parallels in other platforms, etc.

The relationship between the language and the server is pretty well understood to PHP developers in a standard LAMP stack.  Trying to understand the differences between Jetty, Tomcat, Glassfish, etc. is more than a bit daunting (at least it was to me).

Called out comparisons to other Java projects (comparisons to Struts, for example), really don’t do anything for non-Java devs.  Being able to demonstrate ideas and relate them to PHP concepts would be a big help to getting people to appreciate what’s there in Grails more readily.

I’m *not* a full-time Java dev, but I’ve been able to put together ‘real’ Java projects - entire WAR files that can be deployed to Glassfish or Jboss (did both) - because of Grails.  And I was *probably* able to do it faster than an experienced Java developer doing things ‘from scratch’ (just a hunch - I can’t say for certain).  So PHP people looking to expand their skills in the Java world would do quite well to investigate Grails more, but most presentations and material I see gear things towards convincing current Java devs to give Grails and Groovy a spin.  There’s a larger world out there of potential converts.

What do you think?  Would this sort of a talk/presentation interest you?  What other platforms besides PHP might make for useful comparisons?  Perl?  Ruby?

 Did you like this post? Buy me a hot chocolate!

6 Responses to “Coulda woulda shoulda - Grails for PHP developers”

  1. Hans said:

    Yes, absolutely. I was just mentioning to one of my coworkers this morning that I wanted to give Grails a whirl. I’ve done some Java development (so I know what Spring, Hibernate, etc. are) and am always amazed by the myriad of configuration files that must be battled to get even a simple application working on a Java stack. I also hate the developer workflow in Java — reloading Tomcat to check some changes, for instance, when Spring + Hibernate are involved can be a multi-minute affair. If Groovey / Grails brings some simplicity to the Java world, that would be very welcome.

    I also wonder, though, where the “seams” are in this Groovy-Java integration. What happens when you want to do something that Grails doesn’t do “natively”; does it quickly become Java + configuration hell again? I’ve spent some time evaluating a few of these “we make life simple” frameworks that bundle up stuff like Tapestry, Spring, Hibernate. They typically only make life simple if you’re building their demo app. Tapestry especially — OMG! At one point I had two different IoC containers (Tapestry was using HiveMind instead of Spring, but other parts of the app were requiring Spring…) and whole mess of other code components that made absolutely no effort to work with any of the other components. This type of stuff makes things like the .NET framework look oh-so-easy. Even PHP’s framework mess isn’t so bad, because if you have to rewrite a piece that doesn’t fit in with your code, at least it’s really easy.

    So, suffice it to say that I’m really intrigued by the promise of Groovy and Grails, but remain a little skeptical whether an enterprise like that can succeed in the Java landscape.

  2. mgkimsal said:

    Hey Hans! Thanks for the feedback.

    If you need to go outside the Grails world, you’re sort of back in the Java/config hell, but from what I’ve seen there’s still a defined structure where some of those configs would go. Given that you come preconfigured with certain decisions made for you - Spring, etc - you can narrow your focus to things that work with your known stack, rather than going down numerous blind paths in the Java world, picking and choosing disparate libraries.

    The default system comes with an inmemory database and web server and the ‘dev’ mode (default) will recompile files whenever you edit them, so there’s precious little reload/reploy crap going on. In most cases, you edit, save, refresh the browser. I’m still faster than the recompile step sometimes, so I have to wait an extra 1-2 seconds sometimes, but not always.

    Let me know if I can help in any way!

  3. Tomek said:

    As a non-Java developer I have completly no idea what Grails is, so in the first place I would suggest putting some links in that post, so I woudn’t have to use Google :)

  4. mgkimsal said:

    good point - http://www.grails.org for future readers.

  5. Jim Holmes said:

    Hope that “certain someone” wasn’t me!

    Excellent to see you again, and thanks for the great coverage of the event!

  6. mgkimsal said:

    Jim - absosmurfly not! It wasn’t you!

    Thank *YOU* for all *your* hard work in the organizing effort you’ve done over the last year. You publicly thanked everyone else but you had just as much a hand in this as everyone else.

    See you again next year!

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="">