Environment:
Win2K
Java 2 build 1.4.1-b21. Also tried IBM JDK 1.3.
JBoss w/Tomcat 4.0.6, jasper compiled application. Struts and custom tag
libraries.
Problem (short): EXCEPTION_ACCESS_VIOLATION when loading JSP (isolated to
native code getDeclaredConstructors0())
Problem description:
Jasper generates .java files for the JSP. Some of them are quite large,
431KB w/7K lines), but they all compile down to manageable sizes (140K).
When loading the jasper-compiled JSPs (either using load-on-startup or
otherwise), the large JSPs (140K, 142K and 152K) give an access violation
when running getDeclaredConstructors0 (see below for trace).
When debugging it, I can see WebappClassLoader delegate loading of
everything and return the class already loaded, but it dies up after the
classLoader.loadClass() returns and before the native
getDeclaredConstructors0 comes back with the constructors of the class for
initialization by newInstance.
When running under IBM's JDK (using the same exact binaries originally
compiled with Sun's JDK), instead of blowing up it takes 12 minutes or so
and then it finally returns and works fine, but it is still unacceptable
behavior :-)
Our system uses several custom tag libraries that make the source size grow
quite a bit. I'd like to know strategies for limiting the class size for
single items. Using jsp:include only seems to copy the contents of the
originally included file into the item.
If this cannot be fixed per se, I'd like to know about some good strategies
for simplifying the .java files that jasper generates. I read somewhere that
I should use jsp:include, but that is not working (it just copies the
contents over).
Thank you for your attention,
- David Martinez
----------------- Debug log --------------
[INFO,STDOUT] [ SiteActionServlet ] : HttpSession =
org.apache.catalina.session
.StandardSessionFacade@10c0ef2
Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x6D5E723F
Function=JVM_RegisterPerfMethods+0x1309F
Library=c:\JBuilder8\jdk1.4\jre\bin\server\jvm.dll
Current Java thread:
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:1590)
at java.lang.Class.getConstructor0(Class.java:1762)
at java.lang.Class.newInstance0(Class.java:276)
at java.lang.Class.newInstance(Class.java:259)
at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.
java:886)
- locked <04B3A528> (a org.apache.catalina.core.StandardWrapper)
at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.jav
a:655)
- locked <04B3A528> (a org.apache.catalina.core.StandardWrapper)
at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDisp
atcher.java:652)
at
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationD
ispatcher.java:431)
at
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDis
patcher.java:355)
at
com.food.ui.SiteActionServlet.processActionForward(SiteActionServlet.
java:548)
at
org.apache.struts.action.ActionServlet.process(ActionServlet.java:159
5)
at
com.food.ui.SiteActionServlet.processRequest(SiteActionServlet.java:4
09)
at com.food.ui.SiteActionServlet.doGet(SiteActionServlet.java:277)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:247)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:193)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:243)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:566)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:472)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:190)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:566)
at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve
.java:246)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:564)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:472)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:
2347)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:180)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:566)
at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatche
rValve.java:170)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:564)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:170)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:564)
at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
468)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:564)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:472)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:174)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java:566)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:472)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
at
org.apache.ajp.tomcat4.Ajp13Processor.process(Ajp13Processor.java:458
)
at
org.apache.ajp.tomcat4.Ajp13Processor.run(Ajp13Processor.java:551)
at java.lang.Thread.run(Thread.java:536)
Dynamic libraries:
0x00400000 - 0x00406000 c:\JBuilder8\jdk1.4\bin\java.exe
0x77F80000 - 0x77FFB000 C:\WINNT\System32\ntdll.dll
0x77DB0000 - 0x77E0B000 C:\WINNT\system32\ADVAPI32.dll
0x77E80000 - 0x77F31000 C:\WINNT\system32\KERNEL32.dll
0x77D40000 - 0x77DAD000 C:\WINNT\system32\RPCRT4.dll
0x78000000 - 0x78046000 C:\WINNT\system32\MSVCRT.dll
0x6D460000 - 0x6D6DB000 c:\JBuilder8\jdk1.4\jre\bin\server\jvm.dll
0x77E10000 - 0x77E6F000 C:\WINNT\system32\USER32.dll
0x77F40000 - 0x77F79000 C:\WINNT\system32\GDI32.dll
0x77570000 - 0x775A0000 C:\WINNT\System32\WINMM.dll
0x6D1D0000 - 0x6D1D7000 c:\JBuilder8\jdk1.4\jre\bin\hpi.dll
0x6D300000 - 0x6D30D000 c:\JBuilder8\jdk1.4\jre\bin\verify.dll
0x6D210000 - 0x6D229000 c:\JBuilder8\jdk1.4\jre\bin\java.dll
0x6D320000 - 0x6D32D000 c:\JBuilder8\jdk1.4\jre\bin\zip.dll
0x6D260000 - 0x6D27C000 c:\JBuilder8\jdk1.4\jre\bin\jdwp.dll
0x6D170000 - 0x6D175000 c:\JBuilder8\jdk1.4\jre\bin\dt_socket.dll
0x75030000 - 0x75043000 C:\WINNT\System32\ws2_32.dll
0x75020000 - 0x75028000 C:\WINNT\System32\WS2HELP.DLL
0x74FD0000 - 0x74FED000 C:\WINNT\system32\msafd.dll
0x75010000 - 0x75017000 C:\WINNT\System32\wshtcpip.dll
0x6D2D0000 - 0x6D2DE000 C:\JBuilder8\jdk1.4\jre\bin\net.dll
0x75050000 - 0x75058000 C:\WINNT\System32\WSOCK32.dll
0x782C0000 - 0x782CC000 C:\WINNT\System32\rnr20.dll
0x77980000 - 0x779A4000 C:\WINNT\System32\DNSAPI.DLL
0x77340000 - 0x77353000 C:\WINNT\System32\iphlpapi.dll
0x77520000 - 0x77525000 C:\WINNT\System32\ICMP.DLL
0x77320000 - 0x77337000 C:\WINNT\System32\MPRAPI.DLL
0x75150000 - 0x75160000 C:\WINNT\System32\SAMLIB.DLL
0x75170000 - 0x751BF000 C:\WINNT\System32\NETAPI32.DLL
0x77BE0000 - 0x77BEF000 C:\WINNT\System32\Secur32.dll
0x751C0000 - 0x751C6000 C:\WINNT\System32\NETRAP.dll
0x77950000 - 0x77978000 C:\WINNT\system32\WLDAP32.dll
0x77A50000 - 0x77B45000 C:\WINNT\system32\OLE32.DLL
0x779B0000 - 0x77A4B000 C:\WINNT\system32\OLEAUT32.DLL
0x773B0000 - 0x773DE000 C:\WINNT\System32\ACTIVEDS.DLL
0x77380000 - 0x773A2000 C:\WINNT\System32\ADSLDPC.DLL
0x77830000 - 0x7783E000 C:\WINNT\System32\RTUTILS.DLL
0x77880000 - 0x7790D000 C:\WINNT\System32\SETUPAPI.DLL
0x77C10000 - 0x77C6D000 C:\WINNT\System32\USERENV.DLL
0x774E0000 - 0x77512000 C:\WINNT\System32\RASAPI32.DLL
0x774C0000 - 0x774D1000 C:\WINNT\System32\RASMAN.DLL
0x77530000 - 0x77552000 C:\WINNT\System32\TAPI32.DLL
0x71780000 - 0x7180A000 C:\WINNT\system32\COMCTL32.DLL
0x70BD0000 - 0x70C34000 C:\WINNT\system32\SHLWAPI.DLL
0x77360000 - 0x77379000 C:\WINNT\System32\DHCPCSVC.DLL
0x777E0000 - 0x777E8000 C:\WINNT\System32\winrnr.dll
0x777F0000 - 0x777F5000 C:\WINNT\System32\rasadhlp.dll
0x6D2F0000 - 0x6D2F5000 C:\JBuilder8\jdk1.4\jre\bin\rmi.dll
0x77920000 - 0x77943000 C:\WINNT\system32\imagehlp.dll
0x72A00000 - 0x72A2D000 C:\WINNT\system32\DBGHELP.dll
0x690A0000 - 0x690AB000 C:\WINNT\System32\PSAPI.DLL
Local Time = Thu Jan 16 11:20:37 2003
Elapsed Time = 182
#
# HotSpot Virtual Machine Error : EXCEPTION_ACCESS_VIOLATION
# Error ID : 4F530E43505002E6
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Java VM: Java HotSpot(TM) Server VM (1.4.1-b21 mixed mode)
#
# An error report file has been saved as hs_err_pid2144.log.
# Please refer to the file for further information.
#