Abandon Struts for Something (Anything?) Else?

Quite some time ago, I reimplemented all the code in this blog as chains of actions on top of Apache Struts. I did this anticipating new capabilities of Struts 1.3 based on commons-chain -- I figured my architecture would be close, and I could adjust easily.

My application became one big Struts Action class which served as the reused implementation for each configured action, and it just chooses and runs a chain based on the name. I figured my stand-alone chain catalog would be merged into the 1.3 version of the struts-config.xml when that came along, so the duplication of the chain name as a Struts action and a chain name didn't bother me too much at the time. Struts is left parsing my form input and usually mapping my JSP destinations after an execution chain has completed. It also does some UI work rendering forms and building real URLs from logical action names. I use Tiles to template the layout, but that can be had as a separate component these days, so I don't think I can attribute that to Struts anymore. It doesn't sound like my current version of Struts is doing all that much for me anymore, and I have a suspicion that I could find or code these little bits on their own and drop the Struts dependency entirely.

Dropping Struts (and web frameworks entirely) for my next project sounds like a rash decision, so let's look where I could go from here:

The Struts 1.2.x series seems to have stagnated with just minor bug fixes, but still no built-in chaining, so my next project would need to retain much of my existing custom architecture and the duplication of configurations -- that just doesn't feel like progress.

At this point, the Struts development path shatters into lots of confusing little incubating subprojects, none of which ready for any release more official than a nightly build. I've not really been able to wrap my head around any of them, so my following synopses will probably just serve to demonstrate my confusion.

My coding style had led me to chaining actions, and the promise of Struts 1.3 with commons-chain integrated made that look like a straight-forward step. BUT.... Last I've heard, Struts 1.3 will never see a release, so I'll never see the "just Struts plus chaining" version for which I coded. I expect the chaining paradigm will still be incorporated somewhere in newer versions of Struts.

The Struts Shale project mainly integrates JSF with Struts. What incarnation of Struts? I don't know. I've only recently downloaded a nightly build to evaluate it, and I have a lot to learn to grasp the JSF side of the project. JSF has a reputation of ugliness when done by hand outside of the NetBeans IDE and the Matisse GUI builder, and I'm just not ready to enslave myself to any one set of tools yet. Considering that I've actually downloaded and installed some Shale test applications and framework, I must be strongly considering this approach. I think I'd like to make this my opportunity to study JSF.

In another direction, there are reportedly efforts underway to integrate WebWork into Struts -- Struts Action Framework 2.0. It sounds like WebWork has been a popular alternative to Struts. Months and months ago, I had always heard it touted as the solution to my Struts frustrations (like no built-in chaining). This sounds like it could be worth exploring and closer to that which I'm already accustomed, but I don't expect to see this code released any time soon! I'm tempted to just jump to WebWork alone, since I'll need to pretty much relearn everything anyway, but its impending integration into Struts quickly puts it onto the list of dying projects. Will WebWork experience benefit me if the Struts world actually solidifies again?

It feels to me that the Struts world has ripped itself into too many directions and plunged off the progressive scene while several people try to reinvent it. What is "Struts" going to mean on job descriptions and resumes? It would have been better if any of these subprojects had been finished and released (maybe Struts 1.3) to hold our attention before everyone disappeared underground. The only thing they left us was a very stale-tasting Struts 1.2.x tree.

If these subprojects do manage to successfully reemerge from incubation (which gives me a bit of doubt), they'll all end up battling each other for mind share of developers. They may also find that another framework has already eaten their lunch.

So now I ask: what frameworks are thriving in Struts' absence? I'd like to know what to study. Is it plain old JSF?


Filed Under: Blog-Code Technology Java Computers