Tuesday, March 29, 2011

Struts Royally Sucks

I have heard that 100s of times, and I have vague memories of myself struggling, some 7 years ago, against Struts quirks and all those HORRIBLE tag libraries (writing code in XML? Noooooo way.).

I have even hoped to be able to mock Struts, instead of having to deploy in container,
using this http://strutstestcase.sourceforge.net/ framework...

I use MockStrutsTestCase in a very basic setup and I get this:

java.lang.UnsupportedOperationException: getPathTranslated operation is not supported!
at servletunit.HttpServletRequestSimulator.getPathTranslated(HttpServletRequestSimulator.java:635)

no matter what I try...

So I am switching to MockRunner which so far seems to work.

There are also plugins for JUnit and Maven:

This framework is THE BLACK WIDOW MAKER of Front End Developers.

My advice: just throw Struts in the toilet and flush, you will immediately feel an intense relief. Then implement your Front End in Spring MVC or Vaadin.

Here more reasons why Struts sucks.

No comments: