qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject qpid-jms git commit: QPIDJMS-182 clone methods not copying default port values.
Date Wed, 25 May 2016 20:41:02 GMT
Repository: qpid-jms
Updated Branches:
  refs/heads/master bd62df640 -> 19128a577


QPIDJMS-182 clone methods not copying default port values.



Project: http://git-wip-us.apache.org/repos/asf/qpid-jms/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-jms/commit/19128a57
Tree: http://git-wip-us.apache.org/repos/asf/qpid-jms/tree/19128a57
Diff: http://git-wip-us.apache.org/repos/asf/qpid-jms/diff/19128a57

Branch: refs/heads/master
Commit: 19128a577ed90a5b058d73c8617ffee8267a0ec8
Parents: bd62df6
Author: Timothy Bish <tabish121@gmail.com>
Authored: Wed May 25 16:40:31 2016 -0400
Committer: Timothy Bish <tabish121@gmail.com>
Committed: Wed May 25 16:40:45 2016 -0400

----------------------------------------------------------------------
 .../java/org/apache/qpid/jms/transports/TransportOptions.java   | 1 +
 .../org/apache/qpid/jms/transports/TransportSslOptions.java     | 2 ++
 .../org/apache/qpid/jms/transports/TransportOptionsTest.java    | 4 ++++
 .../org/apache/qpid/jms/transports/TransportSslOptionsTest.java | 5 ++++-
 4 files changed, 11 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/19128a57/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportOptions.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportOptions.java
b/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportOptions.java
index 14877f7..78a558f 100644
--- a/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportOptions.java
+++ b/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportOptions.java
@@ -177,6 +177,7 @@ public class TransportOptions implements Cloneable {
         copy.setTcpKeepAlive(isTcpKeepAlive());
         copy.setTcpNoDelay(isTcpNoDelay());
         copy.setTrafficClass(getTrafficClass());
+        copy.setDefaultTcpPort(getDefaultTcpPort());
 
         return copy;
     }

http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/19128a57/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportSslOptions.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportSslOptions.java
b/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportSslOptions.java
index f40c07f..34bd727 100644
--- a/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportSslOptions.java
+++ b/qpid-jms-client/src/main/java/org/apache/qpid/jms/transports/TransportSslOptions.java
@@ -283,6 +283,8 @@ public class TransportSslOptions extends TransportOptions {
         copy.setVerifyHost(isVerifyHost());
         copy.setKeyAlias(getKeyAlias());
         copy.setContextProtocol(getContextProtocol());
+        copy.setDefaultSslPort(getDefaultSslPort());
+
         return copy;
     }
 }

http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/19128a57/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportOptionsTest.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportOptionsTest.java
b/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportOptionsTest.java
index 83fa353..d950c9d 100644
--- a/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportOptionsTest.java
+++ b/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportOptionsTest.java
@@ -35,6 +35,7 @@ public class TransportOptionsTest extends QpidJmsTestCase {
     public static final int TEST_SO_LINGER = Short.MAX_VALUE;
     public static final int TEST_SO_TIMEOUT = 10;
     public static final int TEST_CONNECT_TIMEOUT = 90000;
+    public static final int TEST_DEFAULT_TCP_PORT = 5682;
 
     @Test
     public void testCreate() {
@@ -55,6 +56,7 @@ public class TransportOptionsTest extends QpidJmsTestCase {
         assertEquals(TEST_SO_LINGER, options.getSoLinger());
         assertEquals(TEST_SO_TIMEOUT, options.getSoTimeout());
         assertEquals(TEST_CONNECT_TIMEOUT, options.getConnectTimeout());
+        assertEquals(TEST_DEFAULT_TCP_PORT, options.getDefaultTcpPort());
     }
 
     @Test
@@ -69,6 +71,7 @@ public class TransportOptionsTest extends QpidJmsTestCase {
         assertEquals(TEST_SO_LINGER, options.getSoLinger());
         assertEquals(TEST_SO_TIMEOUT, options.getSoTimeout());
         assertEquals(TEST_CONNECT_TIMEOUT, options.getConnectTimeout());
+        assertEquals(TEST_DEFAULT_TCP_PORT, options.getDefaultTcpPort());
     }
 
     @Test
@@ -135,6 +138,7 @@ public class TransportOptionsTest extends QpidJmsTestCase {
         options.setSoLinger(TEST_SO_LINGER);
         options.setSoTimeout(TEST_SO_TIMEOUT);
         options.setConnectTimeout(TEST_CONNECT_TIMEOUT);
+        options.setDefaultTcpPort(TEST_DEFAULT_TCP_PORT);
 
         return options;
     }

http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/19128a57/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportSslOptionsTest.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportSslOptionsTest.java
b/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportSslOptionsTest.java
index 9bfd2c3..b0d4da4 100644
--- a/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportSslOptionsTest.java
+++ b/qpid-jms-client/src/test/java/org/apache/qpid/jms/transports/TransportSslOptionsTest.java
@@ -16,8 +16,8 @@
  */
 package org.apache.qpid.jms.transports;
 
-import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertArrayEquals;
+import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNull;
 
 import org.apache.qpid.jms.test.QpidJmsTestCase;
@@ -45,6 +45,7 @@ public class TransportSslOptionsTest extends QpidJmsTestCase {
     public static final int TEST_SO_LINGER = Short.MAX_VALUE;
     public static final int TEST_SO_TIMEOUT = 10;
     public static final int TEST_CONNECT_TIMEOUT = 90000;
+    public static final int TEST_DEFAULT_SSL_PORT = 5681;
 
     public static final String[] ENABLED_PROTOCOLS = new String[] {"TLSv1.2"};
     public static final String[] DISABLED_PROTOCOLS = new String[] {"SSLv3", "TLSv1.2"};
@@ -110,6 +111,7 @@ public class TransportSslOptionsTest extends QpidJmsTestCase {
         assertEquals(TEST_SO_LINGER, options.getSoLinger());
         assertEquals(TEST_SO_TIMEOUT, options.getSoTimeout());
         assertEquals(TEST_CONNECT_TIMEOUT, options.getConnectTimeout());
+        assertEquals(TEST_DEFAULT_SSL_PORT, options.getDefaultSslPort());
 
         assertEquals(CLIENT_KEYSTORE, options.getKeyStoreLocation());
         assertEquals(PASSWORD, options.getKeyStorePassword());
@@ -149,6 +151,7 @@ public class TransportSslOptionsTest extends QpidJmsTestCase {
         options.setSoLinger(TEST_SO_LINGER);
         options.setSoTimeout(TEST_SO_TIMEOUT);
         options.setConnectTimeout(TEST_CONNECT_TIMEOUT);
+        options.setDefaultSslPort(TEST_DEFAULT_SSL_PORT);
 
         return options;
     }


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org


Mime
View raw message