You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2014/01/22 07:12:17 UTC

[Bug 56050] New: NPE in WebappClassLoader.clearReferencesJdbc on shutdown

https://issues.apache.org/bugzilla/show_bug.cgi?id=56050

            Bug ID: 56050
           Summary: NPE in WebappClassLoader.clearReferencesJdbc on
                    shutdown
           Product: Tomcat 7
           Version: 7.0.50
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Catalina
          Assignee: dev@tomcat.apache.org
          Reporter: alex.panchenko@gmail.com

We run tomcat with a few web applications, recently tomcat was updated from
7.0.35 to 7.0.50 and now on server shutdown an exception is reported for every
context:

Jan 21, 2014 4:47:06 PM org.apache.catalina.loader.WebappClassLoader
clearReferencesJdbc
WARNING: JDBC driver de-registration failed for web application [/manager]
java.lang.NullPointerException
    at
org.apache.catalina.loader.WebappClassLoader.clearReferencesJdbc(WebappClassLoader.java:2054)
    at
org.apache.catalina.loader.WebappClassLoader.clearReferences(WebappClassLoader.java:1990)
    at
org.apache.catalina.loader.WebappClassLoader.stop(WebappClassLoader.java:1902)
    at
org.apache.catalina.loader.WebappLoader.stopInternal(WebappLoader.java:662)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
    at
org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5527)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
    at
org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1575)
    at
org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1564)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:701)

java -version
java version "1.6.0_27"
OpenJDK Runtime Environment (IcedTea6 1.12.6) (6b27-1.12.6-1ubuntu0.12.04.4)
OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode)

Ubuntu 12.04 with binary packages from
https://launchpad.net/ubuntu/+source/tomcat7

I am sure how it fails, the referenced lines are:

2053:            Class<?> lpClass =
2054:               
defineClass("org.apache.catalina.loader.JdbcLeakPrevention",
2055:                    classBytes, 0, offset,
this.getClass().getProtectionDomain());

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 56050] NPE in WebappClassLoader.clearReferencesJdbc on shutdown

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56050

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |---

--- Comment #2 from Mark Thomas <ma...@apache.org> ---
Ignore my last. I read the stacktrace too quickly. The NPE shouldn't happen.
I'll take a look.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 56050] NPE in WebappClassLoader.clearReferencesJdbc on shutdown

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56050

Konstantin Kolinko <kn...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |NEEDINFO

--- Comment #3 from Konstantin Kolinko <kn...@gmail.com> ---
How can it happen?

http://svn.apache.org/viewvc/tomcat/tc7.0.x/tags/TOMCAT_7_0_50/java/org/apache/catalina/loader/WebappClassLoader.java?view=markup#l2054

The only dereferences on that line are in
"this.getClass().getProtectionDomain()" so "this" is null, or "this.getClass()"
is null?
Both of those should not happen.

Is "ClassLoader.defineClass(..)" a native method on that JVM, so it is not
included in stacktrace?

Is that JVM broken?

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 56050] NPE in WebappClassLoader.clearReferencesJdbc on shutdown

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56050

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |INVALID

--- Comment #1 from Mark Thomas <ma...@apache.org> ---
Please user the users mailing list if you require further assistance with this
warning message about an application memory leak.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 56050] NPE in WebappClassLoader.clearReferencesJdbc on shutdown

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56050

Alex Panchenko <al...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |RESOLVED
         Resolution|---                         |INVALID

--- Comment #4 from Alex Panchenko <al...@gmail.com> ---
Let's close it for now. It had happened a few times in the beginning of the
week on all our servers, but was not happening since then.
Sorry for the false alert.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org