[tomcat] branch 8.5.x updated: Fix the releaseIdleCounter is incorrect.

2023-08-03 Thread lihan
This is an automated email from the ASF dual-hosted git repository.

lihan pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
 new fcdc7e86be Fix the releaseIdleCounter is incorrect.
fcdc7e86be is described below

commit fcdc7e86bed9f59c046598fdd8fb295dc176810e
Author: lihan 
AuthorDate: Fri Aug 4 14:52:50 2023 +0800

Fix the releaseIdleCounter is incorrect.

Fix the releaseIdleCounter does not increment when testAllIdle releases 
them. Pull request #241 provided by Arun Chaitanya Miriappalli
---
 .../src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java| 1 +
 webapps/docs/changelog.xml   | 5 +
 2 files changed, 6 insertions(+)

diff --git 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
index e4f5873d04..6d059b32ca 100644
--- 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
+++ 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
@@ -1142,6 +1142,7 @@ public class ConnectionPool {
 continue;
 }
 if (!con.validate(PooledConnection.VALIDATE_IDLE)) {
+releasedIdleCount.incrementAndGet();
 idle.remove(con);
 release(con);
 }
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 4c2d76803b..51d90d62cd 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -151,6 +151,11 @@
   
   
 
+  
+Fix the releaseIdleCounter does not increment when 
testAllIdle
+releases them. Pull request 241 provided by Arun Chaitanya 
Miriappalli
+(lihan)
+  
   
 Fix the ConnectionState state will be inconsistent with 
actual
 state on the connection when an exception occurs while writing. Pull 
request


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



[tomcat] branch 9.0.x updated: Fix the releaseIdleCounter is incorrect.

2023-08-03 Thread lihan
This is an automated email from the ASF dual-hosted git repository.

lihan pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/9.0.x by this push:
 new 05ed86f850 Fix the releaseIdleCounter is incorrect.
05ed86f850 is described below

commit 05ed86f85028d2a72c83fe417af24dce7442cab9
Author: lihan 
AuthorDate: Fri Aug 4 14:52:50 2023 +0800

Fix the releaseIdleCounter is incorrect.

Fix the releaseIdleCounter does not increment when testAllIdle releases 
them. Pull request #241 provided by Arun Chaitanya Miriappalli
---
 .../src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java| 1 +
 webapps/docs/changelog.xml   | 5 +
 2 files changed, 6 insertions(+)

diff --git 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
index 06989ab807..203abe1a50 100644
--- 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
+++ 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
@@ -1197,6 +1197,7 @@ public class ConnectionPool {
 release = !reconnectIfExpired(con) || 
!con.validate(PooledConnection.VALIDATE_IDLE);
 }
 if (release) {
+releasedIdleCount.incrementAndGet();
 idle.remove(con);
 release(con);
 }
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 79f3ca2f55..e0b4ed7b94 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -168,6 +168,11 @@
   
   
 
+  
+Fix the releaseIdleCounter does not increment when 
testAllIdle
+releases them. Pull request 241 provided by Arun Chaitanya 
Miriappalli
+(lihan)
+  
   
 Fix the ConnectionState state will be inconsistent with 
actual
 state on the connection when an exception occurs while writing. Pull 
request


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



[tomcat] branch 10.1.x updated: Fix the releaseIdleCounter is incorrect.

2023-08-03 Thread lihan
This is an automated email from the ASF dual-hosted git repository.

lihan pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/10.1.x by this push:
 new 11f68a00ce Fix the releaseIdleCounter is incorrect.
11f68a00ce is described below

commit 11f68a00cef1eea95ad1eef94065f5808d32680f
Author: lihan 
AuthorDate: Fri Aug 4 14:52:50 2023 +0800

Fix the releaseIdleCounter is incorrect.

Fix the releaseIdleCounter does not increment when testAllIdle releases 
them. Pull request #241 provided by Arun Chaitanya Miriappalli
---
 .../src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java| 1 +
 webapps/docs/changelog.xml   | 5 +
 2 files changed, 6 insertions(+)

diff --git 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
index 58505cabc6..bc7653b3ac 100644
--- 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
+++ 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
@@ -1204,6 +1204,7 @@ public class ConnectionPool {
 release = !reconnectIfExpired(con) || 
!con.validate(PooledConnection.VALIDATE_IDLE);
 }
 if (release) {
+releasedIdleCount.incrementAndGet();
 idle.remove(con);
 release(con);
 }
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index f069f91ee1..d19f6b45e4 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -147,6 +147,11 @@
   
   
 
+  
+Fix the releaseIdleCounter does not increment when 
testAllIdle
+releases them. Pull request 241 provided by Arun Chaitanya 
Miriappalli
+(lihan)
+  
   
 Fix the ConnectionState state will be inconsistent with 
actual
 state on the connection when an exception occurs while writing. Pull 
request


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



[tomcat] branch main updated: Add a changelog entry for f1e571a9

2023-08-03 Thread lihan
This is an automated email from the ASF dual-hosted git repository.

lihan pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new 71a5ed4ab3 Add a changelog entry for f1e571a9
71a5ed4ab3 is described below

commit 71a5ed4ab3cb69bb3711723791b87e7ce2a5beb6
Author: lihan 
AuthorDate: Fri Aug 4 14:48:55 2023 +0800

Add a changelog entry for f1e571a9
---
 webapps/docs/changelog.xml | 5 +
 1 file changed, 5 insertions(+)

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index f1969a6009..6ee6b5de0e 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -168,6 +168,11 @@
   
   
 
+  
+Fix the releaseIdleCounter does not increment when 
testAllIdle
+releases them. Pull request 241 provided by Arun Chaitanya 
Miriappalli
+(lihan)
+  
   
 Fix the ConnectionState state will be inconsistent with 
actual
 state on the connection when an exception occurs while writing. Pull 
request


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



[GitHub] [tomcat] aooohan merged pull request #241: Increment ReleaseIdle Counter when testAllIdle releases them

2023-08-03 Thread via GitHub


aooohan merged PR #241:
URL: https://github.com/apache/tomcat/pull/241


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


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



[tomcat] branch main updated: Increment ReleaseIdle Counter when testAllIdle releases them

2023-08-03 Thread lihan
This is an automated email from the ASF dual-hosted git repository.

lihan pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new f1e571a9ef Increment ReleaseIdle Counter when testAllIdle releases them
f1e571a9ef is described below

commit f1e571a9ef3026e594c1fbe0fbba3b550f5a02ed
Author: Arun Chaitanya Miriappalli 
AuthorDate: Fri Feb 14 15:39:14 2020 +0800

Increment ReleaseIdle Counter when testAllIdle releases them
---
 .../src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java| 1 +
 1 file changed, 1 insertion(+)

diff --git 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
index 702589fad5..aa8f8154bf 100644
--- 
a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
+++ 
b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java
@@ -1202,6 +1202,7 @@ public class ConnectionPool {
 release = !reconnectIfExpired(con) || 
!con.validate(PooledConnection.VALIDATE_IDLE);
 }
 if (release) {
+releasedIdleCount.incrementAndGet();
 idle.remove(con);
 release(con);
 }


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



[GitHub] [tomcat] aooohan commented on pull request #241: Increment ReleaseIdle Counter when testAllIdle releases them

2023-08-03 Thread via GitHub


aooohan commented on PR #241:
URL: https://github.com/apache/tomcat/pull/241#issuecomment-1665089645

   Ok, you are right. It does seem to have been overlooked.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


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



[Bug 66834] Expression Language 6.0 should be updated to provide the new osgi.contract name for Expression Language 6.0

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66834

Mark Thomas  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 OS||All
 Resolution|--- |FIXED

--- Comment #1 from Mark Thomas  ---
Fixed in:
- 11.0.x for 11.0.0-10 onwards
- 10.1.x for 10.1.12 onwards

10.0.x is no longer supported.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[tomcat] branch 10.1.x updated: Fix BZ 66834 - Correct Java EE contract names to Jakarta EE names

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/10.1.x by this push:
 new dd84c85537 Fix BZ 66834 - Correct Java EE contract names to Jakarta EE 
names
dd84c85537 is described below

commit dd84c8553700284db75711ff42e59e3729b34acc
Author: Mark Thomas 
AuthorDate: Thu Aug 3 20:22:18 2023 +0100

Fix BZ 66834 - Correct Java EE contract names to Jakarta EE names

https://bz.apache.org/bugzilla/show_bug.cgi?id=66834
---
 res/bnd/annotations-api.jar.tmp.bnd | 2 +-
 res/bnd/jaspic-api.jar.tmp.bnd  | 2 +-
 res/bnd/jsp-api.jar.tmp.bnd | 2 +-
 res/bnd/servlet-api.jar.tmp.bnd | 2 +-
 res/bnd/tomcat-embed-el.jar.tmp.bnd | 2 +-
 res/bnd/websocket-api.jar.tmp.bnd   | 2 +-
 webapps/docs/changelog.xml  | 5 +
 7 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/res/bnd/annotations-api.jar.tmp.bnd 
b/res/bnd/annotations-api.jar.tmp.bnd
index 5bbcea4468..0b0ff9292d 100644
--- a/res/bnd/annotations-api.jar.tmp.bnd
+++ b/res/bnd/annotations-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaAnnotation;\
+osgi.contract=JakartaAnnotations;\
 version:Version=${annotation.spec.version};\
 uses:='${packages;NAMED;jakarta.annotation.*}'
 
diff --git a/res/bnd/jaspic-api.jar.tmp.bnd b/res/bnd/jaspic-api.jar.tmp.bnd
index c417cd32b0..088f53632d 100644
--- a/res/bnd/jaspic-api.jar.tmp.bnd
+++ b/res/bnd/jaspic-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaJASPIC;\
+osgi.contract=JakartaAuthentication;\
 version:Version=${jaspic.spec.version};\
 uses:='${packages;NAMED;jakarta.security.auth.message.*}'
 
diff --git a/res/bnd/jsp-api.jar.tmp.bnd b/res/bnd/jsp-api.jar.tmp.bnd
index 9a34133ef5..8d7e5fc52a 100644
--- a/res/bnd/jsp-api.jar.tmp.bnd
+++ b/res/bnd/jsp-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaJSP;\
+osgi.contract=JakartaServerPages;\
 version:Version=${jsp.spec.version};\
 uses:='${packages;NAMED;jakarta.servlet.jsp.*}'
 
diff --git a/res/bnd/servlet-api.jar.tmp.bnd b/res/bnd/servlet-api.jar.tmp.bnd
index aac22a7e4c..09e542cf39 100644
--- a/res/bnd/servlet-api.jar.tmp.bnd
+++ b/res/bnd/servlet-api.jar.tmp.bnd
@@ -23,7 +23,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaServlet;\
+osgi.contract=JakartaServlet;\
 version:Version=${servlet.spec.version};\
 
uses:='${packages;NAMED;jakarta.servlet.*;NAMED;!jakarta.servlet.jsp.*}'
 
diff --git a/res/bnd/tomcat-embed-el.jar.tmp.bnd 
b/res/bnd/tomcat-embed-el.jar.tmp.bnd
index 27320082e0..86fd7a6593 100644
--- a/res/bnd/tomcat-embed-el.jar.tmp.bnd
+++ b/res/bnd/tomcat-embed-el.jar.tmp.bnd
@@ -31,7 +31,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaEL;\
+osgi.contract=JakartaExpressionLanguage;\
 version:Version=${el.spec.version};\
 uses:='${packages;NAMED;jakarta.el.*}'
 
diff --git a/res/bnd/websocket-api.jar.tmp.bnd 
b/res/bnd/websocket-api.jar.tmp.bnd
index 2e7747f701..9f2b0606a5 100644
--- a/res/bnd/websocket-api.jar.tmp.bnd
+++ b/res/bnd/websocket-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaWebSockets;\
+osgi.contract=JakartaWebSocket;\
 version:Version=${websocket.spec.version};\
 uses:='${packages;NAMED;jakarta.websocket.*}'
 
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index f67c67a10b..f069f91ee1 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -174,6 +174,11 @@
 environment variable as intended on Windows when the path to the Java
 executable contains spaces. (markt)
   
+  
+66834: Correct the OSGi contract references in the manifest
+files to refer to the Jakarta EE contract names rather than the Java EE
+contract names. (markt)
+  
 
   
 


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



[tomcat] branch main updated: Fix BZ 66834 - Correct Java EE contract names to Jakarta EE names

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new 0601b8c493 Fix BZ 66834 - Correct Java EE contract names to Jakarta EE 
names
0601b8c493 is described below

commit 0601b8c493d22a5dc4c3441bbfa348377667376a
Author: Mark Thomas 
AuthorDate: Thu Aug 3 20:22:18 2023 +0100

Fix BZ 66834 - Correct Java EE contract names to Jakarta EE names

https://bz.apache.org/bugzilla/show_bug.cgi?id=66834
---
 res/bnd/annotations-api.jar.tmp.bnd | 2 +-
 res/bnd/jaspic-api.jar.tmp.bnd  | 2 +-
 res/bnd/jsp-api.jar.tmp.bnd | 2 +-
 res/bnd/servlet-api.jar.tmp.bnd | 2 +-
 res/bnd/tomcat-embed-el.jar.tmp.bnd | 2 +-
 res/bnd/websocket-api.jar.tmp.bnd   | 2 +-
 webapps/docs/changelog.xml  | 5 +
 7 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/res/bnd/annotations-api.jar.tmp.bnd 
b/res/bnd/annotations-api.jar.tmp.bnd
index 5bbcea4468..0b0ff9292d 100644
--- a/res/bnd/annotations-api.jar.tmp.bnd
+++ b/res/bnd/annotations-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaAnnotation;\
+osgi.contract=JakartaAnnotations;\
 version:Version=${annotation.spec.version};\
 uses:='${packages;NAMED;jakarta.annotation.*}'
 
diff --git a/res/bnd/jaspic-api.jar.tmp.bnd b/res/bnd/jaspic-api.jar.tmp.bnd
index c417cd32b0..088f53632d 100644
--- a/res/bnd/jaspic-api.jar.tmp.bnd
+++ b/res/bnd/jaspic-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaJASPIC;\
+osgi.contract=JakartaAuthentication;\
 version:Version=${jaspic.spec.version};\
 uses:='${packages;NAMED;jakarta.security.auth.message.*}'
 
diff --git a/res/bnd/jsp-api.jar.tmp.bnd b/res/bnd/jsp-api.jar.tmp.bnd
index 9a34133ef5..8d7e5fc52a 100644
--- a/res/bnd/jsp-api.jar.tmp.bnd
+++ b/res/bnd/jsp-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaJSP;\
+osgi.contract=JakartaServerPages;\
 version:Version=${jsp.spec.version};\
 uses:='${packages;NAMED;jakarta.servlet.jsp.*}'
 
diff --git a/res/bnd/servlet-api.jar.tmp.bnd b/res/bnd/servlet-api.jar.tmp.bnd
index aac22a7e4c..09e542cf39 100644
--- a/res/bnd/servlet-api.jar.tmp.bnd
+++ b/res/bnd/servlet-api.jar.tmp.bnd
@@ -23,7 +23,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaServlet;\
+osgi.contract=JakartaServlet;\
 version:Version=${servlet.spec.version};\
 
uses:='${packages;NAMED;jakarta.servlet.*;NAMED;!jakarta.servlet.jsp.*}'
 
diff --git a/res/bnd/tomcat-embed-el.jar.tmp.bnd 
b/res/bnd/tomcat-embed-el.jar.tmp.bnd
index 27320082e0..86fd7a6593 100644
--- a/res/bnd/tomcat-embed-el.jar.tmp.bnd
+++ b/res/bnd/tomcat-embed-el.jar.tmp.bnd
@@ -31,7 +31,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaEL;\
+osgi.contract=JakartaExpressionLanguage;\
 version:Version=${el.spec.version};\
 uses:='${packages;NAMED;jakarta.el.*}'
 
diff --git a/res/bnd/websocket-api.jar.tmp.bnd 
b/res/bnd/websocket-api.jar.tmp.bnd
index 2e7747f701..9f2b0606a5 100644
--- a/res/bnd/websocket-api.jar.tmp.bnd
+++ b/res/bnd/websocket-api.jar.tmp.bnd
@@ -22,7 +22,7 @@ Export-Package: \
 
 Provide-Capability: \
 osgi.contract;\
-osgi.contract=JavaWebSockets;\
+osgi.contract=JakartaWebSocket;\
 version:Version=${websocket.spec.version};\
 uses:='${packages;NAMED;jakarta.websocket.*}'
 
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 2358221c9f..f1969a6009 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -195,6 +195,11 @@
 environment variable as intended on Windows when the path to the Java
 executable contains spaces. (markt)
   
+  
+66834: Correct the OSGi contract references in the manifest
+files to refer to the Jakarta EE contract names rather than the Java EE
+contract names. (markt)
+  
 
   
 


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



[tomcat] branch 8.5.x updated: Fix warning

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
 new 51fabe9c43 Fix warning
51fabe9c43 is described below

commit 51fabe9c43f522d6af47da63429dfd9a0557321f
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:41:58 2023 +0100

Fix warning
---
 .../src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 4712c2e554..5c5280d075 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -92,7 +92,7 @@ public class TestConnectionState extends DefaultTestCase {
 // use our mock driver
 datasource.setDriverClassName(MockErrorDriver.class.getName());
 datasource.setUrl(MockErrorDriver.url);
-datasource.setDefaultAutoCommit(true);
+datasource.setDefaultAutoCommit(Boolean.TRUE);
 datasource.setMinIdle(1);
 datasource.setMaxIdle(1);
 datasource.setMaxActive(1);


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



[tomcat] branch 9.0.x updated: Fix warning

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/9.0.x by this push:
 new ecd39fdc1b Fix warning
ecd39fdc1b is described below

commit ecd39fdc1b91ac7455a7e8f1efc34680b067430d
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:41:58 2023 +0100

Fix warning
---
 .../src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 4712c2e554..5c5280d075 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -92,7 +92,7 @@ public class TestConnectionState extends DefaultTestCase {
 // use our mock driver
 datasource.setDriverClassName(MockErrorDriver.class.getName());
 datasource.setUrl(MockErrorDriver.url);
-datasource.setDefaultAutoCommit(true);
+datasource.setDefaultAutoCommit(Boolean.TRUE);
 datasource.setMinIdle(1);
 datasource.setMaxIdle(1);
 datasource.setMaxActive(1);


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



[tomcat] branch 10.1.x updated: Fix warning

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/10.1.x by this push:
 new 361225c08b Fix warning
361225c08b is described below

commit 361225c08ba351a411d6c64bf0dffa768812ea3d
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:41:58 2023 +0100

Fix warning
---
 .../src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 4712c2e554..5c5280d075 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -92,7 +92,7 @@ public class TestConnectionState extends DefaultTestCase {
 // use our mock driver
 datasource.setDriverClassName(MockErrorDriver.class.getName());
 datasource.setUrl(MockErrorDriver.url);
-datasource.setDefaultAutoCommit(true);
+datasource.setDefaultAutoCommit(Boolean.TRUE);
 datasource.setMinIdle(1);
 datasource.setMaxIdle(1);
 datasource.setMaxActive(1);


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



[tomcat] branch main updated: Fix warning

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new ff1ce0b045 Fix warning
ff1ce0b045 is described below

commit ff1ce0b04502cb4efadeb58d56c4549b6576bbe0
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:41:58 2023 +0100

Fix warning
---
 .../src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 4712c2e554..5c5280d075 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -92,7 +92,7 @@ public class TestConnectionState extends DefaultTestCase {
 // use our mock driver
 datasource.setDriverClassName(MockErrorDriver.class.getName());
 datasource.setUrl(MockErrorDriver.url);
-datasource.setDefaultAutoCommit(true);
+datasource.setDefaultAutoCommit(Boolean.TRUE);
 datasource.setMinIdle(1);
 datasource.setMaxIdle(1);
 datasource.setMaxActive(1);


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



[Bug 66829] setclasspath.bat: troubles when _RUNJAVA contains spaces

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66829

Mark Thomas  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #4 from Mark Thomas  ---
The issue was just with _RUNJAVA and _RUNJDB

Fixed in:
- 11.0.x for 11.0.0-10 onwards
- 10.1.x for 10.1.12 onwards
-  9.0.x for  9.0.79 onwards
-  8.5.x for  8.5.92 onwards

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[tomcat] branch 8.5.x updated: Fix BZ 66829 - fix quoting

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
 new 0fc1feb8c2 Fix BZ 66829 - fix quoting
0fc1feb8c2 is described below

commit 0fc1feb8c2e8768642b47f18976ae9bbef3a9c41
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:32:44 2023 +0100

Fix BZ 66829 - fix quoting

https://bz.apache.org/bugzilla/show_bug.cgi?id=66829
---
 bin/catalina.bat   | 10 +-
 bin/setclasspath.bat   |  4 ++--
 webapps/docs/changelog.xml |  5 +
 3 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/bin/catalina.bat b/bin/catalina.bat
index 84a5f39b48..05704d6115 100755
--- a/bin/catalina.bat
+++ b/bin/catalina.bat
@@ -96,7 +96,7 @@ rem   "-Djdk.tls.ephemeralDHKeySize=2048"
 rem
 rem   CATALINA_LOGGING_CONFIG (Optional) Override Tomcat's logging config file
 rem   Example (all one line)
-rem   set 
CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=%CATALINA_BASE%\conf\logging.properties"
+rem   set 
CATALINA_LOGGING_CONFIG=-Djava.util.logging.config.file="%CATALINA_BASE%\conf\logging.properties"
 rem
 rem   LOGGING_CONFIG  Deprecated
 rem   Use CATALINA_LOGGING_CONFIG
@@ -105,7 +105,7 @@ rem   and LOGGING_CONFIG starts with "-D..."
 rem
 rem   LOGGING_MANAGER (Optional) Override Tomcat's logging manager
 rem   Example (all one line)
-rem   set 
LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager"
+rem   set 
LOGGING_MANAGER=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
 rem
 rem   TITLE   (Optional) Specify the title of Tomcat window. The 
default
 rem   TITLE is Tomcat if it's not specified.
@@ -270,7 +270,7 @@ echo Using JAVA_HOME:   "%JAVA_HOME%"
 echo Using CLASSPATH:   "%CLASSPATH%"
 echo Using CATALINA_OPTS:   "%CATALINA_OPTS%"
 
-set _EXECJAVA=%_RUNJAVA%
+set _EXECJAVA="%_RUNJAVA%"
 set MAINCLASS=org.apache.catalina.startup.Bootstrap
 set ACTION=start
 set SECURITY_POLICY_FILE=
@@ -317,7 +317,7 @@ goto end
 
 :doDebug
 shift
-set _EXECJAVA=%_RUNJDB%
+set _EXECJAVA="%_RUNJDB%"
 set DEBUG_OPTS=-sourcepath "%CATALINA_HOME%\..\..\java"
 if not ""%1"" == ""-security"" goto execCmd
 shift
@@ -336,7 +336,7 @@ goto execCmd
 :doStart
 shift
 if "%TITLE%" == "" set TITLE=Tomcat
-set _EXECJAVA=start "%TITLE%" %_RUNJAVA%
+set _EXECJAVA=start "%TITLE%" "%_RUNJAVA%"
 if not ""%1"" == ""-security"" goto execCmd
 shift
 echo Using Security Manager
diff --git a/bin/setclasspath.bat b/bin/setclasspath.bat
index 1fa46de7d0..bd3a2f1a9d 100755
--- a/bin/setclasspath.bat
+++ b/bin/setclasspath.bat
@@ -87,13 +87,13 @@ rem Don't override _RUNJAVA if the user has set it 
previously
 if not "%_RUNJAVA%" == "" goto gotRunJava
 rem Set standard command for invoking Java.
 rem Also note the quoting as JRE_HOME may contain spaces.
-set _RUNJAVA="%JRE_HOME%\bin\java.exe"
+set "_RUNJAVA=%JRE_HOME%\bin\java.exe"
 :gotRunJava
 
 rem Don't override _RUNJDB if the user has set it previously
 rem Also note the quoting as JAVA_HOME may contain spaces.
 if not "%_RUNJDB%" == "" goto gotRunJdb
-set _RUNJDB="%JAVA_HOME%\bin\jdb.exe"
+set "_RUNJDB=%JAVA_HOME%\bin\jdb.exe"
 :gotRunJdb
 
 goto end
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 47e687e16c..4c2d76803b 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -173,6 +173,11 @@
 Improvements to Japanese translations. Contributed by tak7iji and
 Shirayuking. (markt)
   
+  
+66829: Fix quoting so users can use the 
_RUNJAVA
+environment variable as intended on Windows when the path to the Java
+executable contains spaces. (markt)
+  
 
   
 


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



[tomcat] branch 9.0.x updated: Fix BZ 66829 - fix quoting

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/9.0.x by this push:
 new f107b3c1b7 Fix BZ 66829 - fix quoting
f107b3c1b7 is described below

commit f107b3c1b72e09e105b4d2b7ae97d341ac7e58c6
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:32:44 2023 +0100

Fix BZ 66829 - fix quoting

https://bz.apache.org/bugzilla/show_bug.cgi?id=66829
---
 bin/catalina.bat   | 10 +-
 bin/setclasspath.bat   |  4 ++--
 webapps/docs/changelog.xml |  5 +
 3 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/bin/catalina.bat b/bin/catalina.bat
index 84a5f39b48..05704d6115 100755
--- a/bin/catalina.bat
+++ b/bin/catalina.bat
@@ -96,7 +96,7 @@ rem   "-Djdk.tls.ephemeralDHKeySize=2048"
 rem
 rem   CATALINA_LOGGING_CONFIG (Optional) Override Tomcat's logging config file
 rem   Example (all one line)
-rem   set 
CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=%CATALINA_BASE%\conf\logging.properties"
+rem   set 
CATALINA_LOGGING_CONFIG=-Djava.util.logging.config.file="%CATALINA_BASE%\conf\logging.properties"
 rem
 rem   LOGGING_CONFIG  Deprecated
 rem   Use CATALINA_LOGGING_CONFIG
@@ -105,7 +105,7 @@ rem   and LOGGING_CONFIG starts with "-D..."
 rem
 rem   LOGGING_MANAGER (Optional) Override Tomcat's logging manager
 rem   Example (all one line)
-rem   set 
LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager"
+rem   set 
LOGGING_MANAGER=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
 rem
 rem   TITLE   (Optional) Specify the title of Tomcat window. The 
default
 rem   TITLE is Tomcat if it's not specified.
@@ -270,7 +270,7 @@ echo Using JAVA_HOME:   "%JAVA_HOME%"
 echo Using CLASSPATH:   "%CLASSPATH%"
 echo Using CATALINA_OPTS:   "%CATALINA_OPTS%"
 
-set _EXECJAVA=%_RUNJAVA%
+set _EXECJAVA="%_RUNJAVA%"
 set MAINCLASS=org.apache.catalina.startup.Bootstrap
 set ACTION=start
 set SECURITY_POLICY_FILE=
@@ -317,7 +317,7 @@ goto end
 
 :doDebug
 shift
-set _EXECJAVA=%_RUNJDB%
+set _EXECJAVA="%_RUNJDB%"
 set DEBUG_OPTS=-sourcepath "%CATALINA_HOME%\..\..\java"
 if not ""%1"" == ""-security"" goto execCmd
 shift
@@ -336,7 +336,7 @@ goto execCmd
 :doStart
 shift
 if "%TITLE%" == "" set TITLE=Tomcat
-set _EXECJAVA=start "%TITLE%" %_RUNJAVA%
+set _EXECJAVA=start "%TITLE%" "%_RUNJAVA%"
 if not ""%1"" == ""-security"" goto execCmd
 shift
 echo Using Security Manager
diff --git a/bin/setclasspath.bat b/bin/setclasspath.bat
index 1fa46de7d0..bd3a2f1a9d 100755
--- a/bin/setclasspath.bat
+++ b/bin/setclasspath.bat
@@ -87,13 +87,13 @@ rem Don't override _RUNJAVA if the user has set it 
previously
 if not "%_RUNJAVA%" == "" goto gotRunJava
 rem Set standard command for invoking Java.
 rem Also note the quoting as JRE_HOME may contain spaces.
-set _RUNJAVA="%JRE_HOME%\bin\java.exe"
+set "_RUNJAVA=%JRE_HOME%\bin\java.exe"
 :gotRunJava
 
 rem Don't override _RUNJDB if the user has set it previously
 rem Also note the quoting as JAVA_HOME may contain spaces.
 if not "%_RUNJDB%" == "" goto gotRunJdb
-set _RUNJDB="%JAVA_HOME%\bin\jdb.exe"
+set "_RUNJDB=%JAVA_HOME%\bin\jdb.exe"
 :gotRunJdb
 
 goto end
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 997a2f4434..79f3ca2f55 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -194,6 +194,11 @@
 Improvements to Japanese translations. Contributed by tak7iji and
 Shirayuking. (markt)
   
+  
+66829: Fix quoting so users can use the 
_RUNJAVA
+environment variable as intended on Windows when the path to the Java
+executable contains spaces. (markt)
+  
 
   
 


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



[tomcat] branch main updated: Fix BZ 66829 - fix quoting

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new 6f4b064fec Fix BZ 66829 - fix quoting
6f4b064fec is described below

commit 6f4b064fec4dd99a48d1e2ae11fdc993e9aebe7f
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:32:44 2023 +0100

Fix BZ 66829 - fix quoting

https://bz.apache.org/bugzilla/show_bug.cgi?id=66829
---
 bin/catalina.bat   | 10 +-
 bin/setclasspath.bat   |  4 ++--
 webapps/docs/changelog.xml |  5 +
 3 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/bin/catalina.bat b/bin/catalina.bat
index 6350932852..e2e1c4ac8d 100755
--- a/bin/catalina.bat
+++ b/bin/catalina.bat
@@ -89,11 +89,11 @@ rem   "-Djdk.tls.ephemeralDHKeySize=2048"
 rem
 rem   CATALINA_LOGGING_CONFIG (Optional) Override Tomcat's logging config file
 rem   Example (all one line)
-rem   set 
CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=%CATALINA_BASE%\conf\logging.properties"
+rem   set 
CATALINA_LOGGING_CONFIG=-Djava.util.logging.config.file="%CATALINA_BASE%\conf\logging.properties"
 rem
 rem   LOGGING_MANAGER (Optional) Override Tomcat's logging manager
 rem   Example (all one line)
-rem   set 
LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager"
+rem   set 
LOGGING_MANAGER=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
 rem
 rem   TITLE   (Optional) Specify the title of Tomcat window. The 
default
 rem   TITLE is Tomcat if it's not specified.
@@ -234,7 +234,7 @@ echo Using JAVA_HOME:   "%JAVA_HOME%"
 echo Using CLASSPATH:   "%CLASSPATH%"
 echo Using CATALINA_OPTS:   "%CATALINA_OPTS%"
 
-set _EXECJAVA=%_RUNJAVA%
+set _EXECJAVA="%_RUNJAVA%"
 set MAINCLASS=org.apache.catalina.startup.Bootstrap
 set ACTION=start
 set DEBUG_OPTS=
@@ -277,7 +277,7 @@ goto end
 
 :doDebug
 shift
-set _EXECJAVA=%_RUNJDB%
+set _EXECJAVA="%_RUNJDB%"
 set DEBUG_OPTS=-sourcepath "%CATALINA_HOME%\..\..\java"
 goto execCmd
 
@@ -288,7 +288,7 @@ goto execCmd
 :doStart
 shift
 if "%TITLE%" == "" set TITLE=Tomcat
-set _EXECJAVA=start "%TITLE%" %_RUNJAVA%
+set _EXECJAVA=start "%TITLE%" "%_RUNJAVA%"
 goto execCmd
 
 :doStop
diff --git a/bin/setclasspath.bat b/bin/setclasspath.bat
index 62e5d70cb3..ded6ac13b6 100755
--- a/bin/setclasspath.bat
+++ b/bin/setclasspath.bat
@@ -77,13 +77,13 @@ rem Don't override _RUNJAVA if the user has set it 
previously
 if not "%_RUNJAVA%" == "" goto gotRunJava
 rem Set standard command for invoking Java.
 rem Also note the quoting as JRE_HOME may contain spaces.
-set _RUNJAVA="%JRE_HOME%\bin\java.exe"
+set "_RUNJAVA=%JRE_HOME%\bin\java.exe"
 :gotRunJava
 
 rem Don't override _RUNJDB if the user has set it previously
 rem Also note the quoting as JAVA_HOME may contain spaces.
 if not "%_RUNJDB%" == "" goto gotRunJdb
-set _RUNJDB="%JAVA_HOME%\bin\jdb.exe"
+set "_RUNJDB=%JAVA_HOME%\bin\jdb.exe"
 :gotRunJdb
 
 goto end
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 620ee71966..2358221c9f 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -190,6 +190,11 @@
 Improvements to Japanese translations. Contributed by tak7iji and
 Shirayuking. (markt)
   
+  
+66829: Fix quoting so users can use the 
_RUNJAVA
+environment variable as intended on Windows when the path to the Java
+executable contains spaces. (markt)
+  
 
   
 


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



[tomcat] branch 10.1.x updated: Fix BZ 66829 - fix quoting

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/10.1.x by this push:
 new 0453bc5c9c Fix BZ 66829 - fix quoting
0453bc5c9c is described below

commit 0453bc5c9c06e228dbb39e62a3506a7d3ffae713
Author: Mark Thomas 
AuthorDate: Thu Aug 3 19:32:44 2023 +0100

Fix BZ 66829 - fix quoting

https://bz.apache.org/bugzilla/show_bug.cgi?id=66829
---
 bin/catalina.bat   | 10 +-
 bin/setclasspath.bat   |  4 ++--
 webapps/docs/changelog.xml |  5 +
 3 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/bin/catalina.bat b/bin/catalina.bat
index a5cf1a92f6..9c55ae940e 100755
--- a/bin/catalina.bat
+++ b/bin/catalina.bat
@@ -89,11 +89,11 @@ rem   "-Djdk.tls.ephemeralDHKeySize=2048"
 rem
 rem   CATALINA_LOGGING_CONFIG (Optional) Override Tomcat's logging config file
 rem   Example (all one line)
-rem   set 
CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=%CATALINA_BASE%\conf\logging.properties"
+rem   set 
CATALINA_LOGGING_CONFIG=-Djava.util.logging.config.file="%CATALINA_BASE%\conf\logging.properties"
 rem
 rem   LOGGING_MANAGER (Optional) Override Tomcat's logging manager
 rem   Example (all one line)
-rem   set 
LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager"
+rem   set 
LOGGING_MANAGER=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
 rem
 rem   TITLE   (Optional) Specify the title of Tomcat window. The 
default
 rem   TITLE is Tomcat if it's not specified.
@@ -238,7 +238,7 @@ echo Using JAVA_HOME:   "%JAVA_HOME%"
 echo Using CLASSPATH:   "%CLASSPATH%"
 echo Using CATALINA_OPTS:   "%CATALINA_OPTS%"
 
-set _EXECJAVA=%_RUNJAVA%
+set _EXECJAVA="%_RUNJAVA%"
 set MAINCLASS=org.apache.catalina.startup.Bootstrap
 set ACTION=start
 set SECURITY_POLICY_FILE=
@@ -285,7 +285,7 @@ goto end
 
 :doDebug
 shift
-set _EXECJAVA=%_RUNJDB%
+set _EXECJAVA="%_RUNJDB%"
 set DEBUG_OPTS=-sourcepath "%CATALINA_HOME%\..\..\java"
 if not ""%1"" == ""-security"" goto execCmd
 shift
@@ -304,7 +304,7 @@ goto execCmd
 :doStart
 shift
 if "%TITLE%" == "" set TITLE=Tomcat
-set _EXECJAVA=start "%TITLE%" %_RUNJAVA%
+set _EXECJAVA=start "%TITLE%" "%_RUNJAVA%"
 if not ""%1"" == ""-security"" goto execCmd
 shift
 echo Using Security Manager
diff --git a/bin/setclasspath.bat b/bin/setclasspath.bat
index 62e5d70cb3..ded6ac13b6 100755
--- a/bin/setclasspath.bat
+++ b/bin/setclasspath.bat
@@ -77,13 +77,13 @@ rem Don't override _RUNJAVA if the user has set it 
previously
 if not "%_RUNJAVA%" == "" goto gotRunJava
 rem Set standard command for invoking Java.
 rem Also note the quoting as JRE_HOME may contain spaces.
-set _RUNJAVA="%JRE_HOME%\bin\java.exe"
+set "_RUNJAVA=%JRE_HOME%\bin\java.exe"
 :gotRunJava
 
 rem Don't override _RUNJDB if the user has set it previously
 rem Also note the quoting as JAVA_HOME may contain spaces.
 if not "%_RUNJDB%" == "" goto gotRunJdb
-set _RUNJDB="%JAVA_HOME%\bin\jdb.exe"
+set "_RUNJDB=%JAVA_HOME%\bin\jdb.exe"
 :gotRunJdb
 
 goto end
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index c27bf82c50..f67c67a10b 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -169,6 +169,11 @@
 Improvements to Japanese translations. Contributed by tak7iji and
 Shirayuking. (markt)
   
+  
+66829: Fix quoting so users can use the 
_RUNJAVA
+environment variable as intended on Windows when the path to the Java
+executable contains spaces. (markt)
+  
 
   
 


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



[Bug 66842] Http2AsyncUpgradeHandler does not update overhead count based on sent frames

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66842

Andrew Murphy  changed:

   What|Removed |Added

 CC||ajmurphy...@gmail.com

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[Bug 66842] New: Http2AsyncUpgradeHandler does not update overhead count based on sent frames

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66842

Bug ID: 66842
   Summary: Http2AsyncUpgradeHandler does not update overhead
count based on sent frames
   Product: Tomcat 9
   Version: 9.0.76
  Hardware: PC
OS: Linux
Status: NEW
  Severity: normal
  Priority: P2
 Component: Connectors
  Assignee: dev@tomcat.apache.org
  Reporter: ajmurphy...@gmail.com
  Target Milestone: -

Encountered while testing configurations for
https://bz.apache.org/bugzilla/show_bug.cgi?id=66841








Given an application using Spring server sent event emitters to send
notifications to logged in users and the application sends heartbeat messages
through those SSE emitters to test they are still active. If using a connector
config similar to above (HTTP 2 upgrade and useAsyncIO true) then the data
frames of the heartbeat message will not reduce the overhead count but the
WINDOW_UPDATE frames received in acknowledgement will increase the overhead
count. This causes the overhead count to be exceeded within just a few
heartbeat cycles.

To reproduce:
1. Use NIO2 protocol with Http2Protocol upgrade and useAsyncIO true
2. deploy application with endpoint to create event stream that the application
sends messages on continuously from separate thread
3. Access endpoint from browser (I used chrome but assume it occurs with other
browsers)
4. wait

After each message sent on the event stream a WINDOW_UPDATE frame will be
received which increases the overhead count. Without the data frames of the
sent messages lowering the overhead count the connection will quickly be closed
due to overhead count exceeded.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[Bug 66841] Memory leak from cancelled async http/2 streams

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66841

Andrew Murphy  changed:

   What|Removed |Added

   Severity|critical|regression

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[Bug 66841] Memory leak from cancelled async http/2 streams

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66841

Andrew Murphy  changed:

   What|Removed |Added

 CC||ajmurphy...@gmail.com

--- Comment #1 from Andrew Murphy  ---
Did some additional testing to confirm that the registered Spring SSE emitter
onError callbacks are not being called due to this bug.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[Bug 66841] New: Memory leak from cancelled async http/2 streams

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66841

Bug ID: 66841
   Summary: Memory leak from cancelled async http/2 streams
   Product: Tomcat 9
   Version: 9.0.76
  Hardware: PC
OS: Linux
Status: NEW
  Severity: critical
  Priority: P2
 Component: Connectors
  Assignee: dev@tomcat.apache.org
  Reporter: ajmurphy...@gmail.com
  Target Milestone: -

Regression caused by fixed for
https://bz.apache.org/bugzilla/show_bug.cgi?id=63816

Have application using Spring server sent events for notifying logged in users
of application events. SSE emitters have timeout of 1 day and so are active for
the whole user session. Application tests registered SSE emitters at regular
intervals to confirm the emitter is still alive and perform application cleanup
if the emitter connection has been closed for any reason. Test is done by
sending heartbeat message through each SSE emitter. 

If the SSE connection is cancelled from the remote client, the stream for the
SSE emitter is set to a state of CLOSED_RST_RX which causes the heartbeat test
message to receive a CloseNowException, this is expected based on our
understanding of http/2 and tomcat. However the stream does not actually get
closed because the asyncStateMachine is not updated and remains in a state of
STARTED. This keeps the stream, stream processor, and associated resources from
being closed and garbage collected. Streams in this state are only cleaned up
when their asyncTimeout expires and the AbstractProtocol's timeoutFuture calls
the processor's timeoutAsync method.

The memory used by the closed streams is leaked until they timeout.

The streams appear to be stuck in this state because when the application
attempts to send the heartbeat message the Http2UpgradeHandler calls
doStreamCancel when reserving the window size because the stream state does not
allow writing. doStreamCancel sets the error flag on the stream's
coyoteResponse (Stream.java line 275) and returns the CloseNowException. After
the CloseNowException is returned the AbstractProcessor attempts to set the
error state to CLOSE_NOW (AbstractProcessor line 241) but this fails to update
the asyncStateMachine to an ERROR state because the if condition depends on the
setError flag being true. But the setError flag can never be true in this
scenario because the response error flag had already been set in
doStreamCancel. This means the asyncStateMachine is never set to an error state
or told to process an ERROR SocketEvent.

boolean setError = response.setError();
boolean blockIo = this.errorState.isIoAllowed() &&
!errorState.isIoAllowed();
this.errorState = this.errorState.getMostSevere(errorState);
// Don't change the status code for IOException since that is almost
// certainly a client disconnect in which case it is preferable to keep
// the original status code
http://markmail.org/message/4cxpwmxhtgnrwh7n
if (response.getStatus() < 400 && !(t instanceof IOException)) {
response.setStatus(500);
}
if (t != null) {
request.setAttribute(RequestDispatcher.ERROR_EXCEPTION, t);
}
if (blockIo && isAsync() && setError) { <- setError is always false
if (asyncStateMachine.asyncError()) {
processSocketEvent(SocketEvent.ERROR, true);
}
}

We deployed a patched version of AbstractProcessor with the if condition like
this:

if (blockIo && isAsync() && !asyncStateMachine.isAsyncError()) {

Our assumption is that whether the asyncStateMachine should process an ERROR
event should depend on if the asyncStateMachine is already in an error state
not on if the coyote Response is already in an error state.

Connector settings used:







Note: issue occurred with NIO and APR protocol as well. useAsyncIO had to be
set to false because we encountered a different bug when it was set to true.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



Buildbot success in on tomcat-9.0.x

2023-08-03 Thread buildbot
Build status: Build succeeded!
Worker used: bb_worker2_ubuntu
URL: https://ci2.apache.org/#builders/37/builds/638
Blamelist: Mark Thomas , dependabot[bot] 
<49699333+dependabot[bot]@users.noreply.github.com>, lihan , 
remm 
Build Text: build successful
Status Detected: restored build
Build Source Stamp: [branch 9.0.x] e1ed35a69dc91e6fc431dc3931ab746eadfdec56


Steps:

  worker_preparation: 0

  git: 0

  shell: 0

  shell_1: 0

  shell_2: 0

  shell_3: 0

  shell_4: 0

  shell_5: 0

  compile: 1

  shell_6: 0

  shell_7: 0

  shell_8: 0

  shell_9: 0

  Rsync docs to nightlies.apache.org: 0

  shell_10: 0

  Rsync RAT to nightlies.apache.org: 0

  compile_1: 1

  shell_11: 0

  Rsync Logs to nightlies.apache.org: 0


-- ASF Buildbot


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



[Bug 66829] setclasspath.bat: troubles when _RUNJAVA contains spaces

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66829

--- Comment #3 from Mark Thomas  ---
I think there may be some issues with spaces in the path to Java but the
example in the original report is wrong. It uses

set VAR="value with spaces"

it should be

set "VAR=value with spaces"

I'm continuing to investigate spaces in JAVA_HOME and _RUNJAVA

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[Bug 66829] setclasspath.bat: troubles when _RUNJAVA contains spaces

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66829

--- Comment #2 from Дилян Палаузов  ---
The same problem is described at
https://bz.apache.org/bugzilla/show_bug.cgi?id=66056 

In the bug report I wrote as substutution

> if not defined %_RUNJAVA% goto gotRunJava

but it should be

> if defined _RUNJAVA goto gotRunJava

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[Bug 66829] setclasspath.bat: troubles when _RUNJAVA contains spaces

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66829

Mark Thomas  changed:

   What|Removed |Added

 OS||All

--- Comment #1 from Mark Thomas  ---
For those trying to recreate this, WSL appears to be a red herring. Simply
creating a _RUNJAVA variable containing a space is sufficient to break things.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[Bug 66822] "BindException: Address already in use" - pls say which ip/port is causing the problem

2023-08-03 Thread bugzilla
https://bz.apache.org/bugzilla/show_bug.cgi?id=66822

Mark Thomas  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|UNCONFIRMED |RESOLVED

--- Comment #6 from Mark Thomas  ---
Connector log messages now use the same name format as the protocol handler
(e.g. "http-nio-127.0.0.1-8080") to reference the Connector.

Fixed in:
- 11.0.x for 11.0.0-10 onwards
- 10.1.x for 10.1.12 onwards
-  9.0.x for  9.0.79 onwards
-  8.5.x for  8.5.92 onwards

-- 
You are receiving this mail because:
You are the assignee for the bug.
-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[tomcat] branch 8.5.x updated: Fix BZ 66822. Use same name format for Connector and ProtocolHandler

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
 new bbb2ea5756 Fix BZ 66822. Use same name format for Connector and 
ProtocolHandler
bbb2ea5756 is described below

commit bbb2ea5756d0c5e9b8faf1983c43d37f5087fa19
Author: Mark Thomas 
AuthorDate: Thu Aug 3 14:40:03 2023 +0100

Fix BZ 66822. Use same name format for Connector and ProtocolHandler

https://bz.apache.org/bugzilla/show_bug.cgi?id=66822
---
 java/org/apache/catalina/connector/Connector.java | 19 ---
 webapps/docs/changelog.xml|  4 
 2 files changed, 16 insertions(+), 7 deletions(-)

diff --git a/java/org/apache/catalina/connector/Connector.java 
b/java/org/apache/catalina/connector/Connector.java
index faf6ee2094..61f995be9b 100644
--- a/java/org/apache/catalina/connector/Connector.java
+++ b/java/org/apache/catalina/connector/Connector.java
@@ -1143,14 +1143,19 @@ public class Connector extends LifecycleMBeanBase {
 public String toString() {
 // Not worth caching this right now
 StringBuilder sb = new StringBuilder("Connector[");
-sb.append(getProtocol());
-sb.append('-');
-int port = getPortWithOffset();
-if (port > 0) {
-sb.append(port);
+String name = (String) getProperty("name");
+if (name == null) {
+sb.append(getProtocol());
+sb.append('-');
+int port = getPortWithOffset();
+if (port > 0) {
+sb.append(port);
+} else {
+sb.append("auto-");
+sb.append(getProperty("nameIndex"));
+}
 } else {
-sb.append("auto-");
-sb.append(getProperty("nameIndex"));
+sb.append(name);
 }
 sb.append(']');
 return sb.toString();
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index c908f71a4d..47e687e16c 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -120,6 +120,10 @@
 Catch NamingException in 
JNDIRealm#getPrincipal.
 It is used in Java up to 17 to signal closed connections. (fschumacher)
   
+  
+66822: Use the same naming format in log messages for
+Connector instances as the associated ProtocolHandler instance. (markt)
+  
 
   
   


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



[tomcat] branch 9.0.x updated: Fix BZ 66822. Use same name format for Connector and ProtocolHandler

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/9.0.x by this push:
 new e1ed35a69d Fix BZ 66822. Use same name format for Connector and 
ProtocolHandler
e1ed35a69d is described below

commit e1ed35a69dc91e6fc431dc3931ab746eadfdec56
Author: Mark Thomas 
AuthorDate: Thu Aug 3 14:40:03 2023 +0100

Fix BZ 66822. Use same name format for Connector and ProtocolHandler

https://bz.apache.org/bugzilla/show_bug.cgi?id=66822
---
 java/org/apache/catalina/connector/Connector.java | 27 ++-
 webapps/docs/changelog.xml|  4 
 2 files changed, 20 insertions(+), 11 deletions(-)

diff --git a/java/org/apache/catalina/connector/Connector.java 
b/java/org/apache/catalina/connector/Connector.java
index 64440c5020..fb77d9fb31 100644
--- a/java/org/apache/catalina/connector/Connector.java
+++ b/java/org/apache/catalina/connector/Connector.java
@@ -1095,19 +1095,24 @@ public class Connector extends LifecycleMBeanBase {
 public String toString() {
 // Not worth caching this right now
 StringBuilder sb = new StringBuilder("Connector[");
-sb.append(getProtocol());
-sb.append('-');
-String id = (protocolHandler != null) ? protocolHandler.getId() : null;
-if (id != null) {
-sb.append(id);
-} else {
-int port = getPortWithOffset();
-if (port > 0) {
-sb.append(port);
+String name = (String) getProperty("name");
+if (name == null) {
+sb.append(getProtocol());
+sb.append('-');
+String id = (protocolHandler != null) ? protocolHandler.getId() : 
null;
+if (id != null) {
+sb.append(id);
 } else {
-sb.append("auto-");
-sb.append(getProperty("nameIndex"));
+int port = getPortWithOffset();
+if (port > 0) {
+sb.append(port);
+} else {
+sb.append("auto-");
+sb.append(getProperty("nameIndex"));
+}
 }
+} else {
+sb.append(name);
 }
 sb.append(']');
 return sb.toString();
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 5aaab8f3d5..997a2f4434 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -128,6 +128,10 @@
 Catch NamingException in 
JNDIRealm#getPrincipal.
 It is used in Java up to 17 to signal closed connections. (fschumacher)
   
+  
+66822: Use the same naming format in log messages for
+Connector instances as the associated ProtocolHandler instance. (markt)
+  
 
   
   


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



[tomcat] branch 10.1.x updated: Fix BZ 66822. Use same name format for Connector and ProtocolHandler

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/10.1.x by this push:
 new 895d972aab Fix BZ 66822. Use same name format for Connector and 
ProtocolHandler
895d972aab is described below

commit 895d972aab886aa58ff90535e0f07cbd9a56bb0f
Author: Mark Thomas 
AuthorDate: Thu Aug 3 14:40:03 2023 +0100

Fix BZ 66822. Use same name format for Connector and ProtocolHandler

https://bz.apache.org/bugzilla/show_bug.cgi?id=66822
---
 java/org/apache/catalina/connector/Connector.java | 27 ++-
 webapps/docs/changelog.xml|  4 
 2 files changed, 20 insertions(+), 11 deletions(-)

diff --git a/java/org/apache/catalina/connector/Connector.java 
b/java/org/apache/catalina/connector/Connector.java
index 18e865e157..31acb19fa3 100644
--- a/java/org/apache/catalina/connector/Connector.java
+++ b/java/org/apache/catalina/connector/Connector.java
@@ -1099,19 +1099,24 @@ public class Connector extends LifecycleMBeanBase {
 public String toString() {
 // Not worth caching this right now
 StringBuilder sb = new StringBuilder("Connector[");
-sb.append(getProtocol());
-sb.append('-');
-String id = (protocolHandler != null) ? protocolHandler.getId() : null;
-if (id != null) {
-sb.append(id);
-} else {
-int port = getPortWithOffset();
-if (port > 0) {
-sb.append(port);
+String name = (String) getProperty("name");
+if (name == null) {
+sb.append(getProtocol());
+sb.append('-');
+String id = (protocolHandler != null) ? protocolHandler.getId() : 
null;
+if (id != null) {
+sb.append(id);
 } else {
-sb.append("auto-");
-sb.append(getProperty("nameIndex"));
+int port = getPortWithOffset();
+if (port > 0) {
+sb.append(port);
+} else {
+sb.append("auto-");
+sb.append(getProperty("nameIndex"));
+}
 }
+} else {
+sb.append(name);
 }
 sb.append(']');
 return sb.toString();
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index bd5ba533b3..c27bf82c50 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -116,6 +116,10 @@
 Catch NamingException in 
JNDIRealm#getPrincipal.
 It is used in Java up to 17 to signal closed connections. (fschumacher)
   
+  
+66822: Use the same naming format in log messages for
+Connector instances as the associated ProtocolHandler instance. (markt)
+  
 
   
   


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



[tomcat] branch main updated: Fix BZ 66822. Use same name format for Connector and ProtocolHandler

2023-08-03 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new 8618c293cf Fix BZ 66822. Use same name format for Connector and 
ProtocolHandler
8618c293cf is described below

commit 8618c293cf4c0104d84c2abba425f7d5d5f83323
Author: Mark Thomas 
AuthorDate: Thu Aug 3 14:40:03 2023 +0100

Fix BZ 66822. Use same name format for Connector and ProtocolHandler

https://bz.apache.org/bugzilla/show_bug.cgi?id=66822
---
 java/org/apache/catalina/connector/Connector.java | 27 ++-
 webapps/docs/changelog.xml|  4 
 2 files changed, 20 insertions(+), 11 deletions(-)

diff --git a/java/org/apache/catalina/connector/Connector.java 
b/java/org/apache/catalina/connector/Connector.java
index 1c06a724f2..190c3aa3fa 100644
--- a/java/org/apache/catalina/connector/Connector.java
+++ b/java/org/apache/catalina/connector/Connector.java
@@ -1097,19 +1097,24 @@ public class Connector extends LifecycleMBeanBase {
 public String toString() {
 // Not worth caching this right now
 StringBuilder sb = new StringBuilder("Connector[");
-sb.append(getProtocol());
-sb.append('-');
-String id = (protocolHandler != null) ? protocolHandler.getId() : null;
-if (id != null) {
-sb.append(id);
-} else {
-int port = getPortWithOffset();
-if (port > 0) {
-sb.append(port);
+String name = (String) getProperty("name");
+if (name == null) {
+sb.append(getProtocol());
+sb.append('-');
+String id = (protocolHandler != null) ? protocolHandler.getId() : 
null;
+if (id != null) {
+sb.append(id);
 } else {
-sb.append("auto-");
-sb.append(getProperty("nameIndex"));
+int port = getPortWithOffset();
+if (port > 0) {
+sb.append(port);
+} else {
+sb.append("auto-");
+sb.append(getProperty("nameIndex"));
+}
 }
+} else {
+sb.append(name);
 }
 sb.append(']');
 return sb.toString();
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index cf09e49a8a..620ee71966 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -124,6 +124,10 @@
 presistence process, do not log a warning that null Principals are not
 serializable. Pull request 638 provided by tsryo. (markt)
   
+  
+66822: Use the same naming format in log messages for
+Connector instances as the associated ProtocolHandler instance. (markt)
+  
 
   
   


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



[tomcat] branch 9.0.x updated: Fix imports

2023-08-03 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/9.0.x by this push:
 new 0ffa071f48 Fix imports
0ffa071f48 is described below

commit 0ffa071f481dcd42328522c823057dbf4666f22a
Author: remm 
AuthorDate: Thu Aug 3 14:53:19 2023 +0200

Fix imports
---
 .../test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 73e1044b9f..4712c2e554 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -21,14 +21,14 @@ import java.sql.DriverManager;
 import java.sql.SQLException;
 import java.util.Properties;
 
-import org.apache.tomcat.jdbc.test.driver.Driver;
+import javax.sql.PooledConnection;
+
 import org.junit.Assert;
 import org.junit.Test;
 
 import org.apache.tomcat.jdbc.pool.DataSourceProxy;
 import org.apache.tomcat.jdbc.pool.interceptor.ConnectionState;
-
-import javax.sql.PooledConnection;
+import org.apache.tomcat.jdbc.test.driver.Driver;
 
 public class TestConnectionState extends DefaultTestCase {
 


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



[tomcat] branch 8.5.x updated: Fix imports

2023-08-03 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
 new dfd57d88a7 Fix imports
dfd57d88a7 is described below

commit dfd57d88a7563d42f6d8941c34239adb9960b75e
Author: remm 
AuthorDate: Thu Aug 3 14:53:19 2023 +0200

Fix imports
---
 .../test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 73e1044b9f..4712c2e554 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -21,14 +21,14 @@ import java.sql.DriverManager;
 import java.sql.SQLException;
 import java.util.Properties;
 
-import org.apache.tomcat.jdbc.test.driver.Driver;
+import javax.sql.PooledConnection;
+
 import org.junit.Assert;
 import org.junit.Test;
 
 import org.apache.tomcat.jdbc.pool.DataSourceProxy;
 import org.apache.tomcat.jdbc.pool.interceptor.ConnectionState;
-
-import javax.sql.PooledConnection;
+import org.apache.tomcat.jdbc.test.driver.Driver;
 
 public class TestConnectionState extends DefaultTestCase {
 


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



[tomcat] branch 10.1.x updated: Fix imports

2023-08-03 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/10.1.x by this push:
 new ffd88cc46f Fix imports
ffd88cc46f is described below

commit ffd88cc46ff84cecb2e8077ebfe62500f32c0fc0
Author: remm 
AuthorDate: Thu Aug 3 14:53:19 2023 +0200

Fix imports
---
 .../test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 73e1044b9f..4712c2e554 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -21,14 +21,14 @@ import java.sql.DriverManager;
 import java.sql.SQLException;
 import java.util.Properties;
 
-import org.apache.tomcat.jdbc.test.driver.Driver;
+import javax.sql.PooledConnection;
+
 import org.junit.Assert;
 import org.junit.Test;
 
 import org.apache.tomcat.jdbc.pool.DataSourceProxy;
 import org.apache.tomcat.jdbc.pool.interceptor.ConnectionState;
-
-import javax.sql.PooledConnection;
+import org.apache.tomcat.jdbc.test.driver.Driver;
 
 public class TestConnectionState extends DefaultTestCase {
 


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



[tomcat] branch main updated: Fix imports

2023-08-03 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new 39fa83af2e Fix imports
39fa83af2e is described below

commit 39fa83af2ecf5e6af1aa0f14fb134ce3d3d23538
Author: remm 
AuthorDate: Thu Aug 3 14:53:19 2023 +0200

Fix imports
---
 .../test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
index 73e1044b9f..4712c2e554 100644
--- 
a/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
+++ 
b/modules/jdbc-pool/src/test/java/org/apache/tomcat/jdbc/test/TestConnectionState.java
@@ -21,14 +21,14 @@ import java.sql.DriverManager;
 import java.sql.SQLException;
 import java.util.Properties;
 
-import org.apache.tomcat.jdbc.test.driver.Driver;
+import javax.sql.PooledConnection;
+
 import org.junit.Assert;
 import org.junit.Test;
 
 import org.apache.tomcat.jdbc.pool.DataSourceProxy;
 import org.apache.tomcat.jdbc.pool.interceptor.ConnectionState;
-
-import javax.sql.PooledConnection;
+import org.apache.tomcat.jdbc.test.driver.Driver;
 
 public class TestConnectionState extends DefaultTestCase {
 


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



[GitHub] [tomcat] rmaucher commented on pull request #641: Add DESTROYED state (if DESTROYED we are already STOPPED).

2023-08-03 Thread via GitHub


rmaucher commented on PR #641:
URL: https://github.com/apache/tomcat/pull/641#issuecomment-1663624324

   > Just deleted on the file system or removed via the Manager app?
   > 
   > It looks like there are sorts of race possibilities between `Host` and 
`HostConfig`. How far do we want to go to address these? Since `HostConfig` is 
a `LifecycleListener` for `Host` I think all the hooks we might need are in 
place.
   > 
   > Would it be sufficient to make `HostConfig.check()` (and `check(String)`) 
a NO-OP unless the associated `Host` is in state `STARTED`?
   
   There is no periodic event unless the container is available so this is 
"done" already to some extent. However without a sync it is not fully enforced.
   I think the PR at this point enforces it "more".
   
   Maybe adding synchronized to ContainerBase.backgroundProcess as general 
"sane behavior" ? Also HostConfig.check() and HostConfig.check(String name) 
should sync on the host an recheck getState().isAvailable() to cover when the 
call comes through the manager ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


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



[tomcat] branch main updated: Plan likely package move

2023-08-03 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
 new 09f72a7b0e Plan likely package move
09f72a7b0e is described below

commit 09f72a7b0e78fea1c72be06dc03a78207267de2f
Author: remm 
AuthorDate: Thu Aug 3 10:20:29 2023 +0200

Plan likely package move

This is the AprLifecycleListener equivalent.
---
 .../apache/tomcat/util/net/openssl/panama/OpenSSLLifecycleListener.java  | 1 +
 1 file changed, 1 insertion(+)

diff --git 
a/modules/openssl-foreign/src/main/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLLifecycleListener.java
 
b/modules/openssl-foreign/src/main/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLLifecycleListener.java
index 1ab172db1c..884e502937 100644
--- 
a/modules/openssl-foreign/src/main/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLLifecycleListener.java
+++ 
b/modules/openssl-foreign/src/main/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLLifecycleListener.java
@@ -41,6 +41,7 @@ import org.apache.tomcat.util.res.StringManager;
  * initialization of OpenSSL according to specified configuration parameters.
  * Using the listener is completely optional, but is needed for configuration
  * and full cleanup of a few native memory allocations.
+ * TODO: Move to o.a.catalina.core along with AprLifecycleListener
  */
 public class OpenSSLLifecycleListener implements LifecycleListener {
 


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