RE: xsd version used for web.xml etc

2021-10-21 Thread Jean-Pierre Urkens
My guess, the one that is specified in TOMCAT_BASE/conf/web.xml

-Original Message-
From: S Abirami 
Sent: donderdag 21 oktober 2021 10:46
To: Tomcat Users List 
Subject: xsd version used for web.xml etc

Hi All,

In web.xml, if we didn't define any xsd schema or dtd schema which version
of xsd will be loaded for Tomcat 9.0.45.

Regards,
Abirami.S

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: Issue running Tomcat-8.5.72 with JDK15 under windows as a service

2021-10-19 Thread Jean-Pierre Urkens
The issue is due to a bunch of JVM options that are no longer supported in
Java 15. After cleaning those up the server started normally.

-Original Message-
From: Jean-Pierre Urkens 
Sent: dinsdag 19 oktober 2021 14:46
To: 'users@tomcat.apache.org' 
Subject: Issue running Tomcat-8.5.72 with JDK15 under windows as a service

I am verifying a migration from JDK8 to JDK15 and wanted to setup a Tomcat
8.5 server environment for this test (similar to the Tomcat8.5 with JDK8
we have running for the moment).
I installed the instance as a service under my local (test) windows
environment and configured the JVM  through the java tab. When starting
the service the tomcat deamon fails with:

   CreateJavaVM Failed with error [-6], The system cannot find the
file specified.

References on the net seem to indicate that the problem is with the JVM
setting but the location ' C:\Program
Files\Java\jdk-15.0.1\bin\server\jvm.dll' is correct.
Below the daemon log which shows all JVM options and -D environment
variables set:

[2021-10-19 14:35:23] [debug] ( prunsrv.c:1892) [61340] Apache Commons
Daemon procrun log initialized.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1896) [61340] Apache Commons
Daemon procrun (1.2.4.0 64-bit) started.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1806) [61340] Running Service
'T8N6'...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:1577) [59044] Inside
ServiceMain...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:1032) [59044]
reportServiceStatusE: dwCurrentState = 2, dwWin32ExitCode = 0, dwWaitHint
= 3000, dwServiceSpecificExitCode = 0.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1325) [59044] Starting
service...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:496 ) [59044] Checking Java
options for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dcatalina.home=f:\Tools\apache-tomcat-8.5.72' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dcatalina.base=f:\Tools\apache-tomcat-8.5.72\nodes\node6' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dprofile=local' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dspring.profiles.active=local' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.endorsed.dirs=' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.io.tmpdir=f:\Tools\apache-tomcat-8.5.72\nodes\node6\temp' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.util.logging.config.file=f:\Tools\apache-tomcat-8.5.72\nodes\node6
\conf\logging.properties' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.inte
rnal.jaxp.DocumentBuilderFactoryImpl' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.j
axp.SAXParserFactoryImpl' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.transform.TransformerFactory=com.sun.org.apache.xalan.interna
l.xsltc.trax.TransformerFactoryImpl' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.ephemeralDHKeySize=2048' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.useExtendedMasterSecret=false' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.allowLegacyResumption=true' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.allowLegacyMasterSecret=false' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Xms512m' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Xmx1024m' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:CompileThreshold=8000' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+UseConcMarkSweepGC' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+CMSParallelRemarkEnabled' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+UseCMSInitiatingOccupancyOnly' for environment variable requirements
[2021-10-19 14

RE: Issue running Tomcat-8.5.72 with JDK15 under windows as a service

2021-10-19 Thread Jean-Pierre Urkens
I did had Java 8/15 already on my local system before Java 16,17 came out
and for my migrations the difference between 15, 16 or 17 doesn't really
matter. So I started with what I got instead of installing the latest LTS
version.

Anyway the issue was due to a bunch of JVM options that are no longer
supported since java 8.

Sincerely,

J.P.

-Original Message-
From: logo 
Sent: dinsdag 19 oktober 2021 15:45
To: Tomcat Users List 
Cc: Jean-Pierre Urkens 
Subject: Re: Issue running Tomcat-8.5.72 with JDK15 under windows as a
service

Hi Jean Pierre,


Am 2021-10-19 14:57, schrieb Jean-Pierre Urkens:
> I am verifying a migration from JDK8 to JDK15 and wanted to setup a
> Tomcat
> 8.5 server environment for this test (similar to the Tomcat8.5 with
> JDK8
> we have running for the moment).

certainly not related to your problem, but why are you trying an EOL
version?

Java 15 is out of support since September 2020. Java 17 is out now and the
new LTS version.

Just my 2cts.

Peter

> I installed the instance as a service under my local (test) windows
> environment and configured the JVM  through the java tab. When
> starting the service the tomcat deamon fails with:
>
>CreateJavaVM Failed with error [-6], The system cannot find the
> file specified.
>
> References on the net seem to indicate that the problem is with the
> JVM setting but the location ' C:\Program
> Files\Java\jdk-15.0.1\bin\server\jvm.dll' is correct.
> Below the daemon log which shows all JVM options and -D environment
> variables set:
>
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:1892) [61340] Apache Commons
> Daemon procrun log initialized.
> [2021-10-19 14:35:23] [info]  ( prunsrv.c:1896) [61340] Apache Commons
> Daemon procrun (1.2.4.0 64-bit) started.
> [2021-10-19 14:35:23] [info]  ( prunsrv.c:1806) [61340] Running
> Service 'T8N6'...
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:1577) [59044] Inside
> ServiceMain...
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:1032) [59044]
> reportServiceStatusE: dwCurrentState = 2, dwWin32ExitCode = 0,
> dwWaitHint = 3000, dwServiceSpecificExitCode = 0.
> [2021-10-19 14:35:23] [info]  ( prunsrv.c:1325) [59044] Starting
> service...
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:496 ) [59044] Checking Java
> options for environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Dcatalina.home=f:\Tools\apache-tomcat-8.5.72' for environment
> variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Dcatalina.base=f:\Tools\apache-tomcat-8.5.72\nodes\node6' for
> environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Dprofile=local' for environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Dspring.profiles.active=local' for environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djava.endorsed.dirs=' for environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djava.io.tmpdir=f:\Tools\apache-tomcat-8.5.72\nodes\node6\temp' for
> environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager'
> for environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djava.util.logging.config.file=f:\Tools\apache-tomcat-8.5.72\nodes\n
> ode6 \conf\logging.properties' for environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.
> inte rnal.jaxp.DocumentBuilderFactoryImpl' for environment variable
> requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.intern
> al.j axp.SAXParserFactoryImpl' for environment variable requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djavax.xml.transform.TransformerFactory=com.sun.org.apache.xalan.int
> erna l.xsltc.trax.TransformerFactoryImpl' for environment variable
> requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djdk.tls.ephemeralDHKeySize=2048' for environment variable
> requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djdk.tls.useExtendedMasterSecret=false' for environment variable
> requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-Djdk.tls.allowLegacyResumption=true' for environment variable
> requirements
> [2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
> '-

Issue running Tomcat-8.5.72 with JDK15 under windows as a service

2021-10-19 Thread Jean-Pierre Urkens
I am verifying a migration from JDK8 to JDK15 and wanted to setup a Tomcat
8.5 server environment for this test (similar to the Tomcat8.5 with JDK8
we have running for the moment).
I installed the instance as a service under my local (test) windows
environment and configured the JVM  through the java tab. When starting
the service the tomcat deamon fails with:

   CreateJavaVM Failed with error [-6], The system cannot find the
file specified.

References on the net seem to indicate that the problem is with the JVM
setting but the location ' C:\Program
Files\Java\jdk-15.0.1\bin\server\jvm.dll' is correct.
Below the daemon log which shows all JVM options and -D environment
variables set:

[2021-10-19 14:35:23] [debug] ( prunsrv.c:1892) [61340] Apache Commons
Daemon procrun log initialized.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1896) [61340] Apache Commons
Daemon procrun (1.2.4.0 64-bit) started.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1806) [61340] Running Service
'T8N6'...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:1577) [59044] Inside
ServiceMain...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:1032) [59044]
reportServiceStatusE: dwCurrentState = 2, dwWin32ExitCode = 0, dwWaitHint
= 3000, dwServiceSpecificExitCode = 0.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1325) [59044] Starting
service...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:496 ) [59044] Checking Java
options for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dcatalina.home=f:\Tools\apache-tomcat-8.5.72' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dcatalina.base=f:\Tools\apache-tomcat-8.5.72\nodes\node6' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dprofile=local' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dspring.profiles.active=local' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.endorsed.dirs=' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.io.tmpdir=f:\Tools\apache-tomcat-8.5.72\nodes\node6\temp' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.util.logging.config.file=f:\Tools\apache-tomcat-8.5.72\nodes\node6
\conf\logging.properties' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.inte
rnal.jaxp.DocumentBuilderFactoryImpl' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.j
axp.SAXParserFactoryImpl' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.transform.TransformerFactory=com.sun.org.apache.xalan.interna
l.xsltc.trax.TransformerFactoryImpl' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.ephemeralDHKeySize=2048' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.useExtendedMasterSecret=false' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.allowLegacyResumption=true' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.allowLegacyMasterSecret=false' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Xms512m' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Xmx1024m' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:CompileThreshold=8000' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+UseConcMarkSweepGC' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+CMSParallelRemarkEnabled' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+UseCMSInitiatingOccupancyOnly' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:CMSInitiatingOccupancyFraction=70' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+ScavengeBeforeFullGC' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking

Issue running Tomcat-8.5.72 with JDK15 under windows as a service

2021-10-19 Thread Jean-Pierre Urkens
I am verifying a migration from JDK8 to JDK15 and wanted to setup a Tomcat
8.5 server environment for this test (similar to the Tomcat8.5 with JDK8
we have running for the moment).
I installed the instance as a service under my local (test) windows
environment and configured the JVM  through the java tab. When starting
the service the tomcat deamon fails with:

   CreateJavaVM Failed with error [-6], The system cannot find the
file specified.

References on the net seem to indicate that the problem is with the JVM
setting but the location ' C:\Program
Files\Java\jdk-15.0.1\bin\server\jvm.dll' is correct.
Below the daemon log which shows all JVM options and -D environment
variables set:

[2021-10-19 14:35:23] [debug] ( prunsrv.c:1892) [61340] Apache Commons
Daemon procrun log initialized.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1896) [61340] Apache Commons
Daemon procrun (1.2.4.0 64-bit) started.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1806) [61340] Running Service
'T8N6'...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:1577) [59044] Inside
ServiceMain...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:1032) [59044]
reportServiceStatusE: dwCurrentState = 2, dwWin32ExitCode = 0, dwWaitHint
= 3000, dwServiceSpecificExitCode = 0.
[2021-10-19 14:35:23] [info]  ( prunsrv.c:1325) [59044] Starting
service...
[2021-10-19 14:35:23] [debug] ( prunsrv.c:496 ) [59044] Checking Java
options for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dcatalina.home=f:\Tools\apache-tomcat-8.5.72' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dcatalina.base=f:\Tools\apache-tomcat-8.5.72\nodes\node6' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dprofile=local' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Dspring.profiles.active=local' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.endorsed.dirs=' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.io.tmpdir=f:\Tools\apache-tomcat-8.5.72\nodes\node6\temp' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager' for
environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djava.util.logging.config.file=f:\Tools\apache-tomcat-8.5.72\nodes\node6
\conf\logging.properties' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.inte
rnal.jaxp.DocumentBuilderFactoryImpl' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.j
axp.SAXParserFactoryImpl' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djavax.xml.transform.TransformerFactory=com.sun.org.apache.xalan.interna
l.xsltc.trax.TransformerFactoryImpl' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.ephemeralDHKeySize=2048' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.useExtendedMasterSecret=false' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.allowLegacyResumption=true' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Djdk.tls.allowLegacyMasterSecret=false' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Xms512m' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-Xmx1024m' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:CompileThreshold=8000' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+UseConcMarkSweepGC' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+CMSParallelRemarkEnabled' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+UseCMSInitiatingOccupancyOnly' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:CMSInitiatingOccupancyFraction=70' for environment variable
requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking
'-XX:+ScavengeBeforeFullGC' for environment variable requirements
[2021-10-19 14:35:23] [debug] ( prunsrv.c:500 ) [59044] Checking

RE: Urgent Help

2021-06-23 Thread Jean-Pierre Urkens
What is the servlet-api version indicated in the META-INF/MANIFEST.mf file
contained in the servlet-api.jar. If it is v3.1 (or higher) the
ServletContext.class should contain the method getCloassLoader()? If it is
2.x, it won't.
You might want to check your classpath (checkout Catalina.out to see a dump
of the classpath) to see if there is another jar that might contain
javax.servlet classes that get loaded even before servlet-api.jar.



-Original Message-
From: Mohan T 
Sent: woensdag 23 juni 2021 12:09
To: Tomcat Users List 
Subject: RE: Urgent Help

Hi,

Thanks for the immediate response. I am attaching my file that is used for
starting the tomcat instance. Infact I have  the  servlet-api.jar in tomcat
lib.

I am unable to conclude on this.

Kindly guide me.

Thanks

Mohan
-Original Message-
From: Jean-Pierre Urkens 
Sent: 23 June 2021 15:17
To: Tomcat Users List 
Subject: RE: Urgent Help

CAUTION: You received this email from external Domain. Check reliability of
sender’s email ID. Do not click links, open attachments unless you recognize
the sender and know the content is safe. – Ramco IMG



>From where is the ServletContext.class loaded? Is it from
/lib/servlet-api.jar or from another jar-library on the
classpath? My guess is that you have multiple jars  containing the
ServletContext.class and not all of these are related to the same
servlet-api version and thus not supporting the getClassLoader() method.
You might be loading the wrong SevletContext class file.



-Original Message-
From: Mohan T 
Sent: woensdag 23 juni 2021 11:35
To: Tomcat Users List 
Subject: Urgent Help

Hi,

While starting tomcat, I am getting this error .

Neither the console is starting nor the application is working .

It is tomcat 8.5.35 on linux

Please help

Mohan

23-Jun-2021 14:42:09.857 SEVERE [localhost-startStop-1]
org.apache.catalina.startup.HostConfig.deployWAR Error deploying web
application archive
[/home/ilas/tomcat8.5_tech/apache-tomcat-8.5.35/webapps/admin.war]
java.lang.IllegalStateException: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]]
   at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java
:758)
   at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
   at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
   at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
   at
org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
   at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
   at java.util.concurrent.FutureTask.run(FutureTask.java:266)
   at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1149)
   at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java
:624)
   at java.lang.Thread.run(Thread.java:748)

23-Jun-2021 14:42:09.864 INFO [localhost-startStop-1]
org.apache.catalina.startup.HostConfig.deployWAR Deployment of web
application archive
[/home/ilas/tomcat8.5_tech/apache-tomcat-8.5.35/webapps/admin.war] has
finished in [608] ms
23-Jun-2021 14:42:09.880 INFO [localhost-startStop-1]
org.apache.catalina.startup.HostConfig.deployWAR Deploying web application
archive [/home/ilas/tomcat8.5_tech/apache-tomcat-8.5.35/webapps/audit.war]
23-Jun-2021 14:42:09.927 SEVERE [localhost-startStop-1]
org.apache.catalina.core.ContainerBase.addChildInternal
ContainerBase.addChild: start:
 org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/audit]]
   at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)
   at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java
:754)
   at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
   at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
   at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
   at
org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
   at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
   at java.util.concurrent.FutureTask.run(FutureTask.java:266)
   at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1149)
   at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java
:624)
   at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.NoSuchMethodError:
javax.servlet.ServletContext.getClassLoader()Ljava/lang/ClassLoader;
   at
org.apache.tomcat.util.scan.StandardJarScanner.doScanClassPath(StandardJar
Scanner.java:246)
   at
org.apache.tomcat.util.scan.StandardJarScanner.scan(StandardJarScanner.jav
a:

RE: Urgent Help

2021-06-23 Thread Jean-Pierre Urkens
>From where is the ServletContext.class loaded? Is it from
/lib/servlet-api.jar or from another jar-library on the
classpath? My guess is that you have multiple jars  containing the
ServletContext.class and not all of these are related to the same
servlet-api version and thus not supporting the getClassLoader() method.
You might be loading the wrong SevletContext class file.



-Original Message-
From: Mohan T 
Sent: woensdag 23 juni 2021 11:35
To: Tomcat Users List 
Subject: Urgent Help

Hi,

While starting tomcat, I am getting this error .

Neither the console is starting nor the application is working .

It is tomcat 8.5.35 on linux

Please help

Mohan

23-Jun-2021 14:42:09.857 SEVERE [localhost-startStop-1]
org.apache.catalina.startup.HostConfig.deployWAR Error deploying web
application archive
[/home/ilas/tomcat8.5_tech/apache-tomcat-8.5.35/webapps/admin.war]
java.lang.IllegalStateException: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]]
   at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java
:758)
   at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
   at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
   at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
   at
org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
   at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
   at java.util.concurrent.FutureTask.run(FutureTask.java:266)
   at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1149)
   at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java
:624)
   at java.lang.Thread.run(Thread.java:748)

23-Jun-2021 14:42:09.864 INFO [localhost-startStop-1]
org.apache.catalina.startup.HostConfig.deployWAR Deployment of web
application archive
[/home/ilas/tomcat8.5_tech/apache-tomcat-8.5.35/webapps/admin.war] has
finished in [608] ms
23-Jun-2021 14:42:09.880 INFO [localhost-startStop-1]
org.apache.catalina.startup.HostConfig.deployWAR Deploying web application
archive [/home/ilas/tomcat8.5_tech/apache-tomcat-8.5.35/webapps/audit.war]
23-Jun-2021 14:42:09.927 SEVERE [localhost-startStop-1]
org.apache.catalina.core.ContainerBase.addChildInternal
ContainerBase.addChild: start:
 org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/audit]]
   at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)
   at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java
:754)
   at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
   at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
   at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
   at
org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
   at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
   at java.util.concurrent.FutureTask.run(FutureTask.java:266)
   at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1149)
   at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java
:624)
   at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.NoSuchMethodError:
javax.servlet.ServletContext.getClassLoader()Ljava/lang/ClassLoader;
   at
org.apache.tomcat.util.scan.StandardJarScanner.doScanClassPath(StandardJar
Scanner.java:246)
   at
org.apache.tomcat.util.scan.StandardJarScanner.scan(StandardJarScanner.jav
a:229)
   at
org.apache.catalina.startup.ContextConfig.processJarsForWebFragments(Conte
xtConfig.java:1892)
   at
org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:112
0)
   at
org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.jav
a:769)
   at
org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.jav
a:299)
   at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.ja
va:94)
   at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.jav
a:5154)
   at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 10 more
DISCLAIMER: This communication contains information which is confidential
and the copyright of Ramco Systems Ltd, its subsidiaries or a third party
("Ramco"). This email may also contain legally privileged information.
Confidentiality and legal privilege attached to this communication are not
waived or lost by reason of mistaken delivery to you.This email is
intended to be read or used by the addressee only. If you are not the
intended recipient, any use, distribution, disclosure or copying of this
email is strictly prohibited 

Configuring external CGI script in Tomcat 8.5

2020-06-23 Thread jean-pierre . urkens
Can anyone clarify on how to configure Tomcat 8.5 to serve an external
executable? The CGI-HowTo documentation is VERY unclear to me.

So let's say I have an application installed under 'c:\myApp' that provides
a CGI executable 'c:\myApp\cgi\myapp.exe' now how do I configure Tomcat to
have requests to http://localhost/myApp to call the c:\myApp\cgi\myapp.exe
executable?

 

I tried to add a context.xml file named myapp.xml to
{TOMCAT_BASE}\conf\catalina\localhost with following content:

 





 

But that doesn't seem to work, it will try to download the myapp.exe file.

 

Any instructions are welcome. 

 



RE: Tomcat serving javascript files as text/html

2019-07-12 Thread Jean Pierre Urkens
Hi all,

 

Also css files are served as text/html which causes my pages no longer to be
rendered correctly. It all seems related to a change in Tomcat-8.5.36:

"The default Servlet should not override a previously set content-type.
(remm)"

 

The application sets the content-type in the jsp response file which
includes the js and css files as:

 



 

Any suggestions as to how to circumvent this problem?

 

Thanks in advance.

 

From: Jean Pierre Urkens  
Sent: vrijdag 12 juli 2019 09:28
To: users@tomcat.apache.org
Subject: Tomcat serving javascript files as text/html

 

Hi,

 

I recently upgraded my Tomcat-8.5 installation from 8.5.30 to the latest
version 8.5.43 and I am noticing that js files are served by Tomcat-8.5.43
with content-type: 'text/html' instead of 'application/javascript' as it is
configured in the mime-mappings. 

 

Could someone clarify this (changed) behavior?

 


Met vriendelijke groet,

Jean Pierre Urkens


System Architect


Adv. Dev and Cloud Integration


  +32 (0)14 722162


  +32 (0)478 838336


 <mailto:jean-pierre.urk...@devoteam.com> jean-pierre.urk...@devoteam.com




 <https://www.linkedin.com/company/devoteam> 

 <https://plus.google.com/+Devoteam-group> 

 <https://twitter.com/devoteam> 


 <http://www.devoteam.com/> 

Maatschappelijke zetel Devoteam NV/SA

Belgicastraat 17  - 1930 Zaventem
VAT: BE 0466.475.275  /  RPM Bruxelles - RPR Brussel

 

 



Tomcat serving javascript files as text/html

2019-07-12 Thread Jean Pierre Urkens
Hi,

 

I recently upgraded my Tomcat-8.5 installation from 8.5.30 to the latest
version 8.5.43 and I am noticing that js files are served by Tomcat-8.5.43
with content-type: 'text/html' instead of 'application/javascript' as it is
configured in the mime-mappings. 

 

Could someone clarify this (changed) behavior?

 


Met vriendelijke groet,

Jean Pierre Urkens


System Architect


Adv. Dev and Cloud Integration


  +32 (0)14 722162


  +32 (0)478 838336


 <mailto:jean-pierre.urk...@devoteam.com> jean-pierre.urk...@devoteam.com




 <https://www.linkedin.com/company/devoteam> 

 <https://plus.google.com/+Devoteam-group> 

 <https://twitter.com/devoteam> 


 <http://www.devoteam.com/> 

Maatschappelijke zetel Devoteam NV/SA

Belgicastraat 17  - 1930 Zaventem
VAT: BE 0466.475.275  /  RPM Bruxelles - RPR Brussel

 

 



Tomcat-8.5.37 doesn't respect mime-mapping for css files

2019-02-20 Thread Jean-Pierre Urkens
I upgraded my Tomcat-8.5.30 deployment to 8.5.37 and I am noticing problems
with the way css-files are served by Tomcat.
HTML pages look like:






https://hostname/context/myCSS.css;>

unimportant



When I check the network trace of the browser while downloading this page
it shows 'Content-Type:text/html;charset=UTF-8;' in the response header
both for the page itself but also for the resource "
https://hostname/context/myCSS.css;
although the mime-mapping for css-files is set to 'text/css' in the default
web.xml. This causes the page to be rendered incorrectly by the browser.

Is this a BUG in Tomcat-8.5.37? If so it doesn't yet seem to be listed on
the buglist of Tomcat8. If not how do I force the mime-type 'text/css' for
css files?


Incorrect decoding of encoded HTTP headers

2018-10-03 Thread Jean Pierre Urkens
Hi everybody,

 

I am having an issue where Unicode characters (e.g.  and & #105;) are
passed by the Apache Webserver 2.4 to Tomcat as UTF-8 encoded bytes while
Tomcat seems to evaluate them as ISO-8859-15 encoded.

 

Having taken a network trace with TCPDUMP I see the following bytes for my
header field (truncated the output after byte ‘72’): 

0200   0a 48 54 54 50 5f 56 6f 6f 72 6e 61 61 6d 3a 20   .HTTP_Voornaam: 

0210   4d 61 c5 82 67 6f 72
MaÅ.gor

 

Here the bytes C582 is the UTF-8 encoded value for the Unicode character


 

Now when inspecting the header value in Tomcat using:

   String headerValue = request.getHeader("HTTP_Voornaam");

 

I’m getting the value ‘MaÅ.gor’ which seems to be using the ISO-8859-15
repesentation for the bytes C582. The byte string from the TCPDUMP seems to
match the result of  headerValue.getBytes(Charset.forName("ISO-8859-15"))
and not the result of headerValue.getBytes(Charset.forName("UTF-8")).

 

The FAQ (https://wiki.apache.org/tomcat/FAQ/CharacterEncoding) indicates
that ‘headers are always in US-ASCII encoding. Anything outside of that
needs to be encoded’, in this case it seems to be UTF-8 encoded.

The headers are evaluated by a servlet 2.5 web application which has defined
a ‘CharacterEncodingFilter’ as first filter performing the following
actions:

 request.setCharacterEncoding("UTF-8");

 response.setContentType("text/html; charset=UTF-8");

 response.setCharacterEncoding("UTF-8");

 filterChain.doFilter(request, response);

 

Is there a way to tell Tomcat to decode the headers as being UTF-8 encoded
bytes?

 

I am using Tomcat-version 8.5.32. 

 

Thanks for your support,

 

J.P.



How to set up Tomcat as a client (not a server) for mutual SSL

2018-05-31 Thread Jean Pierre Urkens
I've a web application deployed under Tomcat-8.5.30 that sends  web service
(SOAP) requests (using Axis 1.4 framework) to another web server.

The target server applies mutual SSL and the SSL handshake fails on finding
an appropriate client certificate as requested by the server.

 

I can't seem to figure out how to tell Tomcat which client certificate to
use when requested to sends its client certificate during the handshake.

 

Any help is appreciated

 



RE: Activating Tomcat 8.5 APR on RHEL7

2018-01-16 Thread Jean Pierre Urkens
Thanks, this worked.


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Activating Tomcat 8.5 APR on RHEL7

2018-01-15 Thread Jean Pierre Urkens
I am having problems getting the apr library discovered by Tomcat 8.5. This
is what I tried:

 

1.  I installed Tomcat-8.5 on RHEL-7.

2.  As the native tomcat apr libraries wheren't available on RHEL I made
them myself as instructed by
http://tomcat.apache.org/tomcat-8.5-doc/apr.html. After that the tomcat
native apr libraries where present under '/usr/local/apr/lib'.

3.  To get this library path included in java.library.path I tried:

a.  Create/modify $TOMCAT_BASE/bin/setenv.sh to include the following
two lines:
   LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/apr/lib
   export LD_LIBRARY_PATH
After restarting tomcat the catalina log shows the message:
15-Jan-2018 13:03:31.778 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent The APR based
Apache Tomcat Native library which allows optimal performance in production
environments was not found on the java.library.path:
[/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib]

Apparantly the LD_LIBRARY_PATH isn't taken up by catalina?

b.  I also tried setting environment variables via the command prompt:
#> TOMCAT_HOME=/opt/tomcat8;
#> export TOMCAT_HOME
#> TOMCAT_BASE=/var/lib/tomcat8/nodes/node1; 
#> export TOCAT_BASE
#> LD_LIBRARY_PATH=$LD_LIBARAY_PATH:/usr/local/apr/lib;
#> export LD_LIBRARY_PATH
#> /opt/tomcat8/bin/startup.sh start

But also that is giving the same AprLifecycleListener  message?

 

Could someone clarify what the right way is to get the apr libraries on the
java.library.path of Tomcat8.5?

 


Met vriendelijke groet,

Jean Pierre Urkens


System Architect


Adv. Dev and Cloud Integration


 <tel:+32+14+722162> +32 (0)14 722162


 <tel:+32+478+838336> +32 (0)478 838336


 <mailto:jean-pierre.urk...@devoteam.com> jean-pierre.urk...@devoteam.com




 <https://www.linkedin.com/company/devoteam> 

 <https://plus.google.com/+Devoteam-group> 

 <https://twitter.com/devoteam> 


 <http://www.devoteam.com/> 

Maatschappelijke zetel Devoteam NV/SA

Belgicastraat 17  - 1930 Zaventem
VAT: BE 0466.475.275  /  RPM Bruxelles - RPR Brussel

 

 



RE: Tomcat Xml parser issue

2017-11-16 Thread Jean Pierre Urkens
Vicky,

I am using both SPRING and Oracle XML features in a project and indeed the 
oracle xmlparser installs itself as default parser.

To prevent this I start the VM with following settings (JDK8):

-Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl
 

-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl
 

-Djavax.xml.transform.TransformerFactory=com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl
 

This will force the use of default parsers that come with the JDK/JRE. And when 
I need the Oracle XMLParser (e.g. when handling XMLTYPE records/columns from 
the database) I use (within the code) the Oracle parser.


-Original Message-
From: Vicky B [mailto:vickyb2...@gmail.com] 
Sent: donderdag 16 november 2017 19:30
To: Tomcat Users List 
Subject: Re: Tomcat Xml parser issue

Thanks but the same war works fine is WebSphere and tomcat on Windows it is 
just tomcat provided by  Redhat which work different i.e it throws the exception

On Nov 16, 2017 11:39 PM, "Christopher Schultz" < ch...@christopherschultz.net> 
wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
>
> Vicky,
>
> On 11/16/17 12:24 PM, Vicky B wrote:
> > It is XML parser (DOM and SAX ) from oracle (doc 
> >  > rv
> 2.htm>)
> >
> >
> .
>
> Why do you need a custom XML parser? Why not simply use the one 
> bundled with the JRE?
>
> > Why is tomcat using XMLparserv2
>
> Where is the xmlparserv2.jar file? Some badly-behaved libraries 
> install themselves as the "system" parser when they are used even if 
> they aren't being loaded by the system or application (which doesn't 
> mean YOUR application) ClassLoader. If that happens, you can get weird 
> problems like this.
>
> > tomcat we have in linux machine is from redhat . Why does tomcat 
> > downloaded from apache tomcat site work different form the one 
> > provided by REDHat.
>
> Package managers often make adjustments that make sense for their 
> environments. I suspect that this problem has less to do with RedHat's 
> Tomcat package and more to do with how you deploy your application, 
> its libraries, etc.
>
> > how does class loading work in tomcat.
>
> Tomcat sets up a ClassLoader for itself to work in. For each webapp, a 
> separate ClassLoader is created for them to work in with the Tomcat 
> server ClassLoader as the parent. But the webapp's ClassLoader is a 
> "child-first" ClassLoader meaning that classes and libraries bundled 
> with the application are preferred when code is executing in the 
> application's context.
>
> If you had told us your Tomcat version (or anything else about your 
> environment), we might have been able to help more, but you aren't 
> providing much in the way of information.
>
> Assuming Tomcat 8.0 (because why not?), here is the explanation for 
> how class loading works in Tomcat. Almost as if someone was /trying/ 
> to make that information available for people looking for it.
>
> https://tomcat.apache.org/tomcat-8.0-doc/class-loader-howto.html
>
> - -chris
>
> > On Thu, Nov 16, 2017 at 8:15 PM, Christopher Schultz < 
> > ch...@christopherschultz.net> wrote:
> >
> > Vicky,
> >
> > On 11/16/17 6:53 AM, Vicky B wrote:
>  Hi All,
> 
>  I have application which is using spring , ESAPI and oracle 
>  xmlparserv2.jar , this application works fine in my local tomcat 
>  on windows  but when i deployed in linux server with linux based 
>  apache tomcat i got below error when spring container  was trying 
>  to parse  application specific xmls
> 
>  org.apache.catalina.core.StandardContext.listenerStart
>  Exception sending context initialized event to listener instance 
>  of class org.springframework.web.context.ContextLoaderListener
> 
>  org.springframework.beans.factory.BeanDefinitionStoreException:
> 
> 
> Parser configuration exception parsing XML from class path
>  resource [spring/spring-context.xml]; nested exception is
>  javax.xml.parsers.ParserConfigurationException: Unable to 
>  validate using XSD: Your JAXP provider 
>  [oracle.xml.jaxp.JXDocumentBuilderFactory@526ad194] does not 
>  support XML Schema. Are you running on Java 1.4 with Apache 
>  Crimson? Upgrade to Apache Xerces (or Java 1.5) for full XSD 
>  support.
> 
> 
>  when i removed xmlparserv2.jar from my war file the application 
>  worked fine , what is the issue is this due to class loading 
>  issue or could be possible reason for this issue . Does tomcat 
>  provide xml parser which spring loads.
> >
> > What is xmlparserv2.jar?
> >
> > -chris
> >>
> >> ---
> >> --
> >>
> >>
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> >> For 

DB Connection pool returns stale connections

2017-07-20 Thread Jean Pierre Urkens
Hi All,

 

I'm running Tomcat-8.-5.15 with following Oracle datasource definition:

   

 

Tomcat is using the ojdbc6.jar driver library to connect to an Oracle 12c DB
instance. Initially this datasource declaration seems to work fine.

However when resuming a HTTP session after a period of inactivity the
database pool seems to return stale DB connections. The log file shows

entries like:

 

[IDP] 2017-07-20 11:28:35,655 [T8N2TP1-13] DEBUG $--$
(be.xm.base.database.DBPoolManager:141) - Connection: 502672209,
URL=jdbc:oracle:thin:@zzz:1521:SID, UserName=xxx, Oracle JDBC driver

[IDP] 2017-07-20 11:28:35,656 [T8N2TP1-13] DEBUG $--$
(org.hibernate.impl.SessionImpl:221) - opened session at timestamp:
15005429156

[IDP] 2017-07-20 11:28:35,657 [T8N2TP1-13] DEBUG $--$
(org.hibernate.jdbc.AbstractBatcher:389) - about to open PreparedStatement
(open PreparedStatements: 0, globally: 0)

[IDP] 2017-07-20 11:28:35,657 [T8N2TP1-13] DEBUG $--$
(org.hibernate.jdbc.ConnectionManager:421) - opening JDBC connection

[IDP] 2017-07-20 11:28:54,802 [T8N2TP1-13] DEBUG $--$
(org.hibernate.jdbc.AbstractBatcher:424) - select this_.PERSOONID as
PERSOONID2_0_, this_.rrn as rrn2_0_ from APP_ID_P_RRN.PERSOON this_ where
(this_.rrn like ?)

 

There is almost 20 seconds between opening the JDBC connection and
effectively sending the SQL query. Now the standard HTTP connector in Tomcat
is configured with a connectionTimeout=2 which in this

situation will cause the request to fail.

 

Why does opening the JDBC connection takes so long? Is this an indication
that the DBConnection returned by the DBCP is stale and if so why didn't the
pool cleaned up this connection itself?

 

 

 


Met vriendelijke groet,

Jean Pierre Urkens


System Architect


Adv. Dev and Cloud Integration


 <tel:+32+14+722162> +32 (0)14 722162


 <tel:+32+478+838336> +32 (0)478 838336


 <mailto:jean-pierre.urk...@devoteam.com> jean-pierre.urk...@devoteam.com




 <https://www.linkedin.com/company/devoteam> 

 <https://plus.google.com/+Devoteam-group> 

 <https://twitter.com/devoteam> 


 <http://www.devoteam.com/> 

Maatschappelijke zetel Devoteam NV/SA

Belgicastraat 17  - 1930 Zaventem
VAT: BE 0466.475.275  /  RPM Bruxelles - RPR Brussel