Women in Technology

Hear us Roar



Article:
  Developing for the Web with Ant, Part 2
Subject:   *dont* use Ant's <jspc> task.
Date:   2005-05-26 05:05:04
From:   steve_l
Can I just note that Ant's own <jspc> task is strongly deprecated and should not be used. It will not even work with tomcat 5. The one that ships with Tomcat is what you need.


The jspc task was originally envisaged as a multi-backend task, where you could do back end compilers for tomcat, BEA, WebSphere, etc. But it cant be done. The compilers are too different, and, because they have different jsp to java classname mapping logic (which varies with each version), you cant do a consistent mapper. there are also many other problems, that I wont go in to here.


Either use the <jspc> task with tomcat, or stick the stuff up and use HttpUnit to retrieve every page as part of a rigorous unit test. The latter is good, as it combines functional testing with jsp compilation.