Wednesday September 25, 2002
Upgrading Rampage. I went on an upgrading rampage yesterday and ended the day with the worst feeling. My Struts 1.1b2 application appeared to work fine on most things, however, I kept getting the following error when I tried to submit a form with indexed input values:
java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.apache.commons.beanutils.PropertyUtils.getIndexedProperty(PropertyUtils.java:475) at org.apache.commons.beanutils.PropertyUtils.getIndexedProperty(PropertyUtils.java:410) at org.apache.commons.beanutils.PropertyUtils.getNestedProperty(PropertyUtils.java:749) at org.apache.commons.beanutils.PropertyUtils.getProperty(PropertyUtils.java:780) ... Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0 at java.util.ArrayList.RangeCheck(ArrayList.java:508) at java.util.ArrayList.get(ArrayList.java:320) at com.onpoint.webapp.form.QuestionForm.getAnswer(QuestionForm.java:321)
The items I attempted to upgrade were:
- Jikes 1.15 -> 1.16
- J2SE 1.4.0_01 -> 1.4.1
- Tomcat 4.0.4 -> 4.1.12
- Cactus 1.4 -> 1.4.1
- StrutsTestCase 1.8 -> 1.9
After hours of banging my head against the wall for hours and even trying versions of my code from a week ago, I decided to try the "classic" compiler in Ant. Which I soon learned should now be named "modern." Whalla - it fixed the above problem! My advice - DON'T USE JIKES 1.16 to compile your Struts-based web app! I also found that switching to modern from jikes reduced
my build process from 1 min 20 seconds to 50 seconds - I'm sold. 
I ended up not upgrading to Tomcat 4.1.12 (rather to 4.0.5) because I found that my error-pages were not being recognized. I hope that a client using the application never sees an error page, but if they do - I'd rather them see my pretty page vs. a stacktrace.
Posted in Java
at Sep 25 2002, 06:12:06 AM MDT
Add a Comment
Search This Site
Recent Entries
- Secure JSON Services with Play Scala and SecureSocial
- My What's New in Spring 3.1 Presentation
- Twitter's Open Source Summit: Bootstrap 2.0 Edition
- Refreshing AppFuse's UI with Twitter Bootstrap
- 2011 - A Year in Review
- Upgrading AppFuse to Spring Security 3.1 and Spring 3.1
- What have I been working on at Taleo?
- Our Engaging Trip to Paris and Antwerp
- My HTML5 with Play Scala, CoffeeScript and Jade Presentation from Devoxx 2011
- Deploying Java and Play Framework Apps to the Cloud with James Ward