You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by "David Jencks (JIRA)" <de...@geronimo.apache.org> on 2006/06/03 00:14:30 UTC

[jira] Created: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

No methodProxy in EJBInvocation at startup under heavy load
-----------------------------------------------------------

         Key: GERONIMO-2079
         URL: http://issues.apache.org/jira/browse/GERONIMO-2079
     Project: Geronimo
        Type: Bug
    Security: public (Regular issues) 
  Components: OpenEJB  
    Versions: 1.1    
    Reporter: David Jencks
     Fix For: 1.2


After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:

java.lang.NullPointerException
        at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
        at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
        at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
        at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
        at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
        at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
        at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
        at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
        at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
        at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
        at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
        at java.lang.Thread.run(Thread.java:534)                                                                                                              

Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

Posted by "David Jencks (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2079?page=all ]

David Jencks updated GERONIMO-2079:
-----------------------------------

    Fix Version/s: Wish List
                       (was: 1.2)
         Assignee: Matt Hogstrom  (was: David Jencks)

Is this a performance decrease we should worry about?

> No methodProxy in EJBInvocation at startup under heavy load
> -----------------------------------------------------------
>
>                 Key: GERONIMO-2079
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2079
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: OpenEJB
>    Affects Versions: 1.1
>            Reporter: David Jencks
>         Assigned To: Matt Hogstrom
>             Fix For: Wish List
>
>         Attachments: 2079.patch, GERONIMO-2079.failed1.patch
>
>
> After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:
> java.lang.NullPointerException
>         at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
>         at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
>         at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>         at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
>         at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
>         at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
>         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>         at java.lang.Thread.run(Thread.java:534)                                                                                                              
> Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

Posted by "David Jencks (JIRA)" <de...@geronimo.apache.org>.
    [ http://issues.apache.org/jira/browse/GERONIMO-2079?page=comments#action_12415653 ] 

David Jencks commented on GERONIMO-2079:
----------------------------------------

Applied dains patch in openejb rev 2670.  It removes the startup errors but
- by looking at it I can't convince myself it doesn't use double-checked locking (but I might be stupid)
- it appears to further reduce the performance to ~1100 page views/sec.

> No methodProxy in EJBInvocation at startup under heavy load
> -----------------------------------------------------------
>
>          Key: GERONIMO-2079
>          URL: http://issues.apache.org/jira/browse/GERONIMO-2079
>      Project: Geronimo
>         Type: Bug
>     Security: public(Regular issues) 
>   Components: OpenEJB
>     Versions: 1.1
>     Reporter: David Jencks
>     Assignee: David Jencks
>      Fix For: 1.2
>  Attachments: 2079.patch, GERONIMO-2079.failed1.patch
>
> After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:
> java.lang.NullPointerException
>         at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
>         at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
>         at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>         at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
>         at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
>         at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
>         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>         at java.lang.Thread.run(Thread.java:534)                                                                                                              
> Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

Posted by "Dain Sundstrom (JIRA)" <de...@geronimo.apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2079?page=all ]

Dain Sundstrom updated GERONIMO-2079:
-------------------------------------

    Attachment: 2079.patch

New patch which puts all transient data in the proxy factory into a single object.  Access to this data is controlled by a synchronized block.  A volatile could be used, but a synchronized block is easier for people to understand and this code should not have a performance impact.  This is because each interceptor copies the data once from the proxy factory, so the this will only impact the first invocation on a proxy. 

I also cleaned up the initialization code in the interceptor. 

> No methodProxy in EJBInvocation at startup under heavy load
> -----------------------------------------------------------
>
>          Key: GERONIMO-2079
>          URL: http://issues.apache.org/jira/browse/GERONIMO-2079
>      Project: Geronimo
>         Type: Bug
>     Security: public(Regular issues) 
>   Components: OpenEJB
>     Versions: 1.1
>     Reporter: David Jencks
>     Assignee: David Jencks
>      Fix For: 1.2
>  Attachments: 2079.patch, GERONIMO-2079.failed1.patch
>
> After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:
> java.lang.NullPointerException
>         at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
>         at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
>         at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>         at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
>         at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
>         at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
>         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>         at java.lang.Thread.run(Thread.java:534)                                                                                                              
> Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Resolved: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

Posted by "David Jencks (JIRA)" <de...@geronimo.apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2079?page=all ]
     
David Jencks resolved GERONIMO-2079:
------------------------------------

    Resolution: Fixed

This is not cglib's problem at all, we managed to create a nice race condition.  It should be fixed in openejb rev 2665 but this hasn't been tested much.

> No methodProxy in EJBInvocation at startup under heavy load
> -----------------------------------------------------------
>
>          Key: GERONIMO-2079
>          URL: http://issues.apache.org/jira/browse/GERONIMO-2079
>      Project: Geronimo
>         Type: Bug
>     Security: public(Regular issues) 
>   Components: OpenEJB
>     Versions: 1.1
>     Reporter: David Jencks
>     Assignee: David Jencks
>      Fix For: 1.2

>
> After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:
> java.lang.NullPointerException
>         at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
>         at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
>         at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>         at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
>         at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
>         at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
>         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>         at java.lang.Thread.run(Thread.java:534)                                                                                                              
> Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Assigned: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

Posted by "David Jencks (JIRA)" <de...@geronimo.apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2079?page=all ]

David Jencks reassigned GERONIMO-2079:
--------------------------------------

    Assign To: David Jencks

> No methodProxy in EJBInvocation at startup under heavy load
> -----------------------------------------------------------
>
>          Key: GERONIMO-2079
>          URL: http://issues.apache.org/jira/browse/GERONIMO-2079
>      Project: Geronimo
>         Type: Bug
>     Security: public(Regular issues) 
>   Components: OpenEJB
>     Versions: 1.1
>     Reporter: David Jencks
>     Assignee: David Jencks
>      Fix For: 1.2

>
> After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:
> java.lang.NullPointerException
>         at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
>         at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
>         at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>         at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
>         at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
>         at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
>         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>         at java.lang.Thread.run(Thread.java:534)                                                                                                              
> Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

Posted by "David Jencks (JIRA)" <de...@geronimo.apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2079?page=all ]

David Jencks updated GERONIMO-2079:
-----------------------------------

    Attachment: GERONIMO-2079.failed1.patch

My attempts to fix this so far haven't worked.  I've attached a patch of my latest failing effort  and rolled the code back to its state before my first failed fix.

I believe the problem is that the actual race condition occurs in EJBProxyFactory rather than EJBMethodInterceptor, so a similar solution inside EJBProxyFactory might work.

IIUC this change resulted in a ~20% performance decrease from 1500 page views/sec to 1200.  If we can eliminate the volatile in even some circumstances it would seem worthwhile to do so.

> No methodProxy in EJBInvocation at startup under heavy load
> -----------------------------------------------------------
>
>          Key: GERONIMO-2079
>          URL: http://issues.apache.org/jira/browse/GERONIMO-2079
>      Project: Geronimo
>         Type: Bug
>     Security: public(Regular issues) 
>   Components: OpenEJB
>     Versions: 1.1
>     Reporter: David Jencks
>     Assignee: David Jencks
>      Fix For: 1.2
>  Attachments: GERONIMO-2079.failed1.patch
>
> After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:
> java.lang.NullPointerException
>         at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
>         at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
>         at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>         at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
>         at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
>         at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
>         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>         at java.lang.Thread.run(Thread.java:534)                                                                                                              
> Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Reopened: (GERONIMO-2079) No methodProxy in EJBInvocation at startup under heavy load

Posted by "David Jencks (JIRA)" <de...@geronimo.apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2079?page=all ]
     
David Jencks reopened GERONIMO-2079:
------------------------------------


kevan pointed out that although the fix makes operationMap work, it leaves all the other fields in an indeterminate state.  We need something better.

My first thought was to initialize everything in the constructor or readObject method.  This won't work because in general the target container won't be deployed when a proxy as part of an ejb ref is deserialized.  There's no way around this, since the target might be in an app that hasn't started or even been installed/deployed yet.

My current thought is to try to put all the info into a data object which is put into a volatile field.  Comments and suggestions very welcome.

> No methodProxy in EJBInvocation at startup under heavy load
> -----------------------------------------------------------
>
>          Key: GERONIMO-2079
>          URL: http://issues.apache.org/jira/browse/GERONIMO-2079
>      Project: Geronimo
>         Type: Bug
>     Security: public(Regular issues) 
>   Components: OpenEJB
>     Versions: 1.1
>     Reporter: David Jencks
>     Assignee: David Jencks
>      Fix For: 1.2

>
> After deploying daytrader, if you apply heavy load (50 threads) you get about 60 exceptions like this:
> java.lang.NullPointerException
>         at org.openejb.proxy.EJBMethodInterceptor.createEJBInvocation(EJBMethodInterceptor.java:203)
>         at org.openejb.proxy.EJBMethodInterceptor.intercept(EJBMethodInterceptor.java:131)
>         at org.openejb.proxy.EntityEJBLocalObject$$EnhancerByCGLIB$$84c9ae5f.getDataBean(<generated>)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doGet(PingServlet2EntityLocal.java:126)
>         at org.apache.geronimo.samples.daytrader.web.prims.PingServlet2EntityLocal.doPost(PingServlet2EntityLocal.java:54)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>         at org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjectValve.java:46)
>         at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:342)
>         at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:31)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
>         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>         at java.lang.Thread.run(Thread.java:534)                                                                                                              
> Looking into the code, it appears that cglib is calling EJBMethodInterceptor with a null methodProxy.  After these startup exceptions, which appear to occur within the first 2 seconds of load, there are no further exceptions: i ran it for 17 minutes at 1200 pages/sec.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira