You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Pierre <ge...@sympatico.ca> on 2000/10/19 21:15:44 UTC

Code size from user tags compilation

JSP and struts ease of use can be dangerous...

I had a page where the user can select a country from a combo-box. Instead of
packaging the whole stuff in a property of my ActionForm, I decided to use
the well known method of cut-n'-paste from an old application and change the
original <select> and <option> tags to <struts:select> and <struts:option>.
Why use Java code for such a simple behavior?

The reason is simple: The code for the generated servlet is 13643 lines long,
changing every simple <struts:option> to 35 lines of Java, multiplied by the
number of countries...
The ice on the cake is the error message, when trying to call the page:
Error 500 - Code of a method longuer than 65535 bytes

Now, I have to check with the <struts:options> tag and hope that the resulting
code can be compiled...

Pierre Metras