trafodion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lium...@apache.org
Subject [1/2] trafodion git commit: TRAFODION-2932 ConnectionTimeout value for jdbc cannot lager than 32768
Date Sun, 04 Feb 2018 01:22:08 GMT
Repository: trafodion
Updated Branches:
  refs/heads/master 1f55c285b -> 700c8a5d5


TRAFODION-2932 ConnectionTimeout value for jdbc cannot lager than 32768


Project: http://git-wip-us.apache.org/repos/asf/trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafodion/commit/c72e47eb
Tree: http://git-wip-us.apache.org/repos/asf/trafodion/tree/c72e47eb
Diff: http://git-wip-us.apache.org/repos/asf/trafodion/diff/c72e47eb

Branch: refs/heads/master
Commit: c72e47eb49e3612d531353cd56d4a81735ba95f7
Parents: 47713b9
Author: mashengchen <mashengchen@gmail.com>
Authored: Sun Jan 28 17:45:23 2018 +0800
Committer: mashengchen <mashengchen@gmail.com>
Committed: Sun Jan 28 17:45:23 2018 +0800

----------------------------------------------------------------------
 .../src/main/java/org/trafodion/jdbc/t4/T4Properties.java       | 5 +++++
 1 file changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafodion/blob/c72e47eb/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/T4Properties.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/T4Properties.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/T4Properties.java
index 8530b8c..be9d90f 100644
--- a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/T4Properties.java
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/T4Properties.java
@@ -1292,6 +1292,11 @@ public class T4Properties {
 	 * @see #setServerDataSource(String)
 	 */
 	void setConnectionTimeout(int connectionTimeout) {
+        if (connectionTimeout > Short.MAX_VALUE) {
+            sqlExceptionMessage_ = "Incorrect value for connectionTimeout set: [" + connectionTimeout
+                    + "]. Max value is: [" + Short.MAX_VALUE + "]";
+        }
+
 		if (connectionTimeout < 0) {
 			/*
 			 * sqlExceptionMessage_ = "Incorrect value for connectionTimeout


Mime
View raw message