[Design of POJO Server] - Re: Strange classloading behavior -- thread stuck
by adrian@jboss.org
"adrian(a)jboss.org" wrote : I think I know what the problem is, but if I'm correct it will be very difficult to reproduce the problem.
|
The reason I think it will be difficult to reproduce the problem is because
I think this only occurs when you hit the ClassCircularity bug.
The releaseInNextTask == true means that it got a temporary lock on the classloader.
Its not the original classloader used to initiate the classloading attempt.
This can only occur if the thread owns the classloader so it should in normal circumstances be able to complete the task, release the classloader and reschedule back the other requests.
If however, it hits the ClassCircularity problem (see the catch block just above the unlock), it will reschedule that task. So when it does the unlock, it will loop
on the reassignment of the task back to the same thread.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4206700#4206700
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4206700
16 years, 10 months
[Design of POJO Server] - Re: Strange classloading behavior -- thread stuck
by adrian@jboss.org
I think I know what the problem is, but if I'm correct it will be very difficult to
reproduce the problem.
If you look at the old code in JBoss4, LoadMgr3 in nextTask()
when releaseInNextTask == true just removes the lock on the classloader
and unassigns the current thread as the owner of the classloader.
The important part is that it doesn't try to reschedule any outstanding tasks
back to their original threads. That only occurs in endLoadTask().
| if( threadTask.releaseInNextTask == true )
| {
| if( trace )
| log.trace("Releasing loadLock and ownership of UCL: "+threadTask.ucl);
| synchronized( registrationLock )
| {
| loadClassThreads.remove(threadTask.ucl);
| }
| synchronized( threadTask.ucl )
| {
| ucl3.release();
| ucl3.notifyAll();
| }
| }
|
While in JBoss5, it does:
| if (threadTask.isReleaseInNextTask())
| threadTask.getClassLoader().unlock();
|
The classloader unlock() will always try to reassign the outstanding tasks
when it invokes ClassLoaderManager.unregisterLoaderThread()
so it is reassigning tasks in both places.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4206697#4206697
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4206697
16 years, 10 months
[Design of POJO Server] - Chasing illegal URL
by alesj
With the latest VFS (2.2.0-SNAPSHOT) I'm getting this exception
when hitting Seam Booking app (although it deployes and eventually renders fine):
| 17:36:00,921 ERROR [compiler] Error Loading Library: vfszip:/C:/projects/branches/jbossas/Branch_5_0/build/output/jboss-5.0.1.GA/server/default/deploy/jboss-seam-booking.ear/jboss-seam-booking.war/WEB-INF/lib/richfaces-ui.jar/META-INFa4j.taglib.xml
| java.io.IOException: Cannot find child, root=DelegatingHandler@29869763[path= context=file:/C:/projects/branches/jbossas/Branch_5_0/build/output/jboss-5.0.1.GA/server/default/tmp/ax61p-eoep9z-fqqskbc4-1-fqqskoem-o/jboss-seam-booking.ear real=vfszip:/
| C:/projects/branches/jbossas/Branch_5_0/build/output/jboss-5.0.1.GA/server/default/tmp/ax61p-eoep9z-fqqskbc4-1-fqqskoem-o/jboss-seam-booking.ear], relativePath=/jboss-seam-booking.war/WEB-INF/lib/richfaces-ui.jar/META-INFa4j.taglib.xml/, uri=vfszip:/
| C:/projects/branches/jbossas/Branch_5_0/build/output/jboss-5.0.1.GA/server/default/deploy/jboss-seam-booking.ear/jboss-seam-booking.war/WEB-INF/lib/richfaces-ui.jar/META-INFa4j.taglib.xml
| at org.jboss.virtual.plugins.registry.DefaultVFSRegistry.getFile(DefaultVFSRegistry.java:83)
| at org.jboss.virtual.plugins.registry.DefaultVFSRegistry.getFile(DefaultVFSRegistry.java:106)
| at org.jboss.virtual.protocol.AbstractVFSHandler.openConnection(AbstractVFSHandler.java:71)
| at java.net.URL.openConnection(URL.java:943)
| at java.net.URL.openStream(URL.java:1007)
| at com.sun.facelets.compiler.TagLibraryConfig.create(TagLibraryConfig.java:404)
| at com.sun.facelets.compiler.TagLibraryConfig.loadImplicit(TagLibraryConfig.java:431)
| at com.sun.facelets.compiler.Compiler.initialize(Compiler.java:87)
| at com.sun.facelets.compiler.Compiler.compile(Compiler.java:104)
| at com.sun.facelets.impl.DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:218)
| at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:149)
| at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:100)
| at com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:517)
| at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:567)
| at org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:108)
| at org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:196)
| at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:110)
| at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
| at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
| at javax.faces.webapp.FacesServlet.service(FacesServlet.java:266)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
| at org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:51)
See META-INFa4j.taglib.xml, missing '/'.
Any other means of chasing down where this illegal URL comes from,
apart from looking at all the related sources?
As I've been pushing log into VFS for the last couple of hours w/o success ... ;-(
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4206640#4206640
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4206640
16 years, 10 months