This is an automated email from the ASF dual-hosted git repository. markt pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit cad93e885ab5526a44c91832b7c4d0c5dca7bab2 Author: KangZhiDong <world...@gmail.com> AuthorDate: Fri Sep 6 22:53:51 2019 +0800 fix typo(an sql) --- java/org/apache/catalina/realm/JDBCRealm.java | 6 +++--- java/org/apache/tomcat/dbcp/dbcp2/Jdbc41Bridge.java | 4 ++-- java/org/apache/tomcat/dbcp/dbcp2/SQLExceptionList.java | 2 +- .../apache/tomcat/dbcp/dbcp2/managed/LocalXAConnectionFactory.java | 4 ++-- modules/jdbc-pool/doc/jdbc-pool.xml | 2 +- .../main/java/org/apache/tomcat/jdbc/pool/PoolConfiguration.java | 4 ++-- .../src/main/java/org/apache/tomcat/jdbc/pool/TrapException.java | 2 +- .../main/java/org/apache/tomcat/jdbc/pool/mbeans-descriptors.xml | 4 ++-- 8 files changed, 14 insertions(+), 14 deletions(-) diff --git a/java/org/apache/catalina/realm/JDBCRealm.java b/java/org/apache/catalina/realm/JDBCRealm.java index 2f11177..f27d9ac 100644 --- a/java/org/apache/catalina/realm/JDBCRealm.java +++ b/java/org/apache/catalina/realm/JDBCRealm.java @@ -306,7 +306,7 @@ public class JDBCRealm // This needs rewritten with better pooling support, the existing code // needs signature changes since the Prepared statements needs cached // with the connections. - // The code below will try twice if there is a SQLException so the + // The code below will try twice if there is an SQLException so the // connection may try to be opened again. On normal conditions (including // invalid login - the above is only used once. int numberOfTries = 2; @@ -509,7 +509,7 @@ public class JDBCRealm // This needs rewritten with better pooling support, the existing code // needs signature changes since the Prepared statements needs cached // with the connections. - // The code below will try twice if there is a SQLException so the + // The code below will try twice if there is an SQLException so the // connection may try to be opened again. On normal conditions (including // invalid login - the above is only used once. int numberOfTries = 2; @@ -581,7 +581,7 @@ public class JDBCRealm // This needs rewritten wuth better pooling support, the existing code // needs signature changes since the Prepared statements needs cached // with the connections. - // The code below will try twice if there is a SQLException so the + // The code below will try twice if there is an SQLException so the // connection may try to be opened again. On normal conditions (including // invalid login - the above is only used once. int numberOfTries = 2; diff --git a/java/org/apache/tomcat/dbcp/dbcp2/Jdbc41Bridge.java b/java/org/apache/tomcat/dbcp/dbcp2/Jdbc41Bridge.java index eb0d09d..0cb852a 100644 --- a/java/org/apache/tomcat/dbcp/dbcp2/Jdbc41Bridge.java +++ b/java/org/apache/tomcat/dbcp/dbcp2/Jdbc41Bridge.java @@ -415,7 +415,7 @@ public class Jdbc41Bridge { * Delegates to {@link Statement#closeOnCompletion()} without throwing a {@link AbstractMethodError}. * <p> * If the JDBC driver does not implement {@link Statement#closeOnCompletion()}, then just check that the connection - * is closed to then throw a SQLException. + * is closed to then throw an SQLException. * </p> * * @param statement @@ -438,7 +438,7 @@ public class Jdbc41Bridge { * Delegates to {@link Statement#isCloseOnCompletion()} without throwing a {@link AbstractMethodError}. * <p> * If the JDBC driver does not implement {@link Statement#isCloseOnCompletion()}, then just check that the - * connection is closed to then throw a SQLException. + * connection is closed to then throw an SQLException. * </p> * * @param statement diff --git a/java/org/apache/tomcat/dbcp/dbcp2/SQLExceptionList.java b/java/org/apache/tomcat/dbcp/dbcp2/SQLExceptionList.java index 6f24f04..3f8d1af 100644 --- a/java/org/apache/tomcat/dbcp/dbcp2/SQLExceptionList.java +++ b/java/org/apache/tomcat/dbcp/dbcp2/SQLExceptionList.java @@ -21,7 +21,7 @@ import java.sql.SQLException; import java.util.List; /** - * A SQLException based on a list of Throwable causes. + * An SQLException based on a list of Throwable causes. * <p> * The first exception in the list is used as this exception's cause and is accessible with the usual * {@link #getCause()} while the complete list is accessible with {@link #getCauseList()}. diff --git a/java/org/apache/tomcat/dbcp/dbcp2/managed/LocalXAConnectionFactory.java b/java/org/apache/tomcat/dbcp/dbcp2/managed/LocalXAConnectionFactory.java index 1c6dee2..d5e176a 100644 --- a/java/org/apache/tomcat/dbcp/dbcp2/managed/LocalXAConnectionFactory.java +++ b/java/org/apache/tomcat/dbcp/dbcp2/managed/LocalXAConnectionFactory.java @@ -66,7 +66,7 @@ public class LocalXAConnectionFactory implements XAConnectionFactory { * @param flag * ignored * @throws XAException - * if connection.commit() throws a SQLException + * if connection.commit() throws an SQLException */ @Override public synchronized void commit(final Xid xid, final boolean flag) throws XAException { @@ -216,7 +216,7 @@ public class LocalXAConnectionFactory implements XAConnectionFactory { * @param xid * the id of the transaction branch for this connection * @throws XAException - * if connection.rollback() throws a SQLException + * if connection.rollback() throws an SQLException */ @Override public synchronized void rollback(final Xid xid) throws XAException { diff --git a/modules/jdbc-pool/doc/jdbc-pool.xml b/modules/jdbc-pool/doc/jdbc-pool.xml index 890fe40..852b83b 100644 --- a/modules/jdbc-pool/doc/jdbc-pool.xml +++ b/modules/jdbc-pool/doc/jdbc-pool.xml @@ -119,7 +119,7 @@ <subsection name="Additional features"> <p>The Tomcat connection pool offers a few additional features over what most other pools let you do:</p> <ul> - <li><code>initSQL</code> - the ability to run a SQL statement exactly once, when the connection is created</li> + <li><code>initSQL</code> - the ability to run an SQL statement exactly once, when the connection is created</li> <li><code>validationInterval</code> - in addition to running validations on connections, avoid running them too frequently.</li> <li><code>jdbcInterceptors</code> - flexible and pluggable interceptors to create any customizations around the pool, the query execution and the result set handling. More on this in the advanced section.</li> diff --git a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/PoolConfiguration.java b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/PoolConfiguration.java index 2359fc8..4ce7708 100644 --- a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/PoolConfiguration.java +++ b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/PoolConfiguration.java @@ -501,7 +501,7 @@ public interface PoolConfiguration { * The SQL query that will be used to validate connections from this * pool before returning them to the caller or pool. * If specified, this query does not have to return any data, - * it just can't throw a SQLException. + * it just can't throw an SQLException. * The default value is null. * Example values are SELECT 1(mysql), * select 1 from dual(oracle), @@ -514,7 +514,7 @@ public interface PoolConfiguration { * The SQL query that will be used to validate connections from this * pool before returning them to the caller or pool. * If specified, this query does not have to return any data, - * it just can't throw a SQLException. + * it just can't throw an SQLException. * The default value is null. * Example values are SELECT 1(mysql), * select 1 from dual(oracle), diff --git a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/TrapException.java b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/TrapException.java index ccbbbf9..2789e72 100644 --- a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/TrapException.java +++ b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/TrapException.java @@ -23,7 +23,7 @@ import java.lang.reflect.Method; import java.sql.SQLException; /** * Interceptor that traps any unhandled exception types and throws an exception that has been declared by the method - * called, or throw a SQLException if it is declared. + * called, or throw an SQLException if it is declared. * If the caught exception is not declared, and the method doesn't throw SQLException, then this interceptor will * throw a RuntimeException * diff --git a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/mbeans-descriptors.xml b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/mbeans-descriptors.xml index 7dfd1c3..aa38a15 100644 --- a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/mbeans-descriptors.xml +++ b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/mbeans-descriptors.xml @@ -117,7 +117,7 @@ writeable="false"/> <attribute name="maxWait" - description="The time to wait in milliseconds before a SQLException is thrown when a connection is requested" + description="The time to wait in milliseconds before an SQLException is thrown when a connection is requested" type="java.lang.Integer" writeable="false"/> @@ -214,7 +214,7 @@ writeable="false"/> <attribute name="initSQL" - description="A SQL executed once per connection, when it is established" + description="An SQL executed once per connection, when it is established" type="java.lang.String" writeable="false"/> --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org