Terence, thanks for your reply! best, Jenny
On Sun, Jun 2, 2024 at 3:11 AM Terence M. Bandoian <tere...@tmbsw.com>
wrote:

> A long time ago (Tomcat 7), I would see a Tomcat memory leak detection
> error on shutdown if the JDBC driver was located in WEB-INF/lib but not
> if it was in the Tomcat lib directory. Explicitly de-registering the
> driver with a ServletContextListener on shutdown eliminated the error.
> I'm not sure if that's still necessary or if it applies in your case.
>
> -Terence Bandoian
>
> On 6/2/2024 1:56 AM, Christopher Schultz wrote:
> > Jenny,
> >
> > (Apologies for top-posting)
> >
> > “Safely ignored” can mean many things. You are only in danger of running
> out of heap space. So if you aren’t worried about that, feel free to ignore
> the error message.
> >
> > If it were my system, I would want to ensure a clean unload of the
> driver when the application shuts down.
> >
> > But I don’t think it will harm anything besides your memory usage.
> >
> > -chris
> >
> >> On Jun 1, 2024, at 00:18, Ying Jin<jiny4...@gmail.com>  wrote:
> >>
> >> Chris,
> >>
> >> Thanks for your reply!
> >>
> >> We already removed the ojdbc8.jar file from the application's
> Web-inf/lib
> >> folder as suggested in the following post, however, we still got the
> >> warning messages below after the application is deployed to the Tomcat 9
> >> server.
> >>
> >>
> https://stackoverflow.com/questions/6981564/why-must-the-jdbc-driver-be-put-in-tomcat-home-lib-folder
> >>
> >> WARNING: The web application [Our Web Application Name] appears to have
> >> started a thread named [InterruptTimer] but has failed to stop it. This
> is
> >> very likely to create a memory leak. Stack trace of thread:
> >>
> >> WARNING: The web application [Our Web Application Name] appears to have
> >> started a thread named [oracle.jdbc.diagnostics.Diagnostic.CLOCK] but
> has
> >> failed to stop it. This is very likely to create a memory leak. Stack
> trace
> >> of thread:
> >>
> >> I also read some posts saying these warning messages can be safely
> ignored
> >> if the Tomcat version is greater than 7.0. I'm not sure if this is
> correct
> >> or not.
> >>
> >> Please advise,
> >>
> >> Many thanks!
> >> Jenny
> >>
> >>> On Fri, May 31, 2024 at 3:50 PM Christopher Schultz <
> >>> ch...@christopherschultz.net> wrote:
> >>>
> >>> Jenny,
> >>>
> >>>> On 5/31/24 14:52, Ying Jin wrote:
> >>>> We removed the ojdbc8 driver jar from web-inf/lib from the web
> >>>> application and kept the ojdbc8 jar file in the Tomcat/lib folder, but
> >>>> we still can see the following memory link warning message whenever we
> >>>> redeploy the web application. We use the Tomcat 9 server in the Linux
> >>>> environment.
> >>> This list strips attachments. Can you re-post with text-only?
> >>>
> >>>> The other warning message is about the "validateFile Problem with jar
> >>>> file /tomcat/lib/jolokia.jar. My question is if we can safely ignore
> >>>> these warning messages or not.
> >>>>
> >>>> It would be great if you can shed some light on this issue.
> >>> If the message is something like "driver cannot be unloaded" then check
> >>> Tomcat with a debugger or even something like JVisualVM to see how many
> >>> WebappClassLoaders you have in memory.
> >>>
> >>> If the driver causes the web application ClassLoader to be "pinned" in
> >>> memory, then it will never be removed and all those classes will
> >>> continue to use-up heap space until you restart the JVM. This gets
> worse
> >>> every time you reload your application without restarting the JVM. The
> >>> Manager application web UI can help you diagnose these a little.
> >>>
> >>> The validation problem with the Jolokia JAR file will depend upon
> >>> exactly what it says. I would first get a replacement copy of the
> >>> Jolokia JAR file before bothering to try to diagnose it any further.
> >>>
> >>> -chris
> >>>
> >>> ---------------------------------------------------------------------
> >>> To unsubscribe, e-mail:users-unsubscr...@tomcat.apache.org
> >>> For additional commands, e-mail:users-h...@tomcat.apache.org
> >>>
> >>>
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail:users-unsubscr...@tomcat.apache.org
> > For additional commands, e-mail:users-h...@tomcat.apache.org
> >
>
>

Reply via email to