trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bri...@apache.org
Subject [1/2] git commit: TS-2574: Sharing server sessions per thread doesn't work when doing https to http
Date Mon, 23 Jun 2014 17:08:23 GMT
Repository: trafficserver
Updated Branches:
  refs/heads/master 26c7f37fe -> 16b15e256


TS-2574: Sharing server sessions per thread doesn't work when doing https to http


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

Branch: refs/heads/master
Commit: b6c6d8de26b2bfbcd251febc8dfbff9d7ab677df
Parents: 26c7f37
Author: Brian Geffon <briang@apache.org>
Authored: Mon Jun 23 10:07:09 2014 -0700
Committer: Brian Geffon <briang@apache.org>
Committed: Mon Jun 23 10:07:09 2014 -0700

----------------------------------------------------------------------
 iocore/net/SSLNetProcessor.cc | 14 ++++++++++----
 proxy/Main.cc                 |  4 +++-
 2 files changed, 13 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/b6c6d8de/iocore/net/SSLNetProcessor.cc
----------------------------------------------------------------------
diff --git a/iocore/net/SSLNetProcessor.cc b/iocore/net/SSLNetProcessor.cc
index eb48672..622dd89 100644
--- a/iocore/net/SSLNetProcessor.cc
+++ b/iocore/net/SSLNetProcessor.cc
@@ -65,13 +65,19 @@ SSLNetProcessor::start(int number_of_ssl_threads, size_t stacksize)
     SSLError("Can't initialize the SSL client, HTTPS in remap rules will not function");
   }
 
-  if (number_of_ssl_threads < 1) {
-    return -1;
-  }
-
   // Initialize SSL statistics. This depends on an initial set of certificates being loaded
above.
   SSLInitializeStatistics();
 
+  if (number_of_ssl_threads == -1) {
+    // We've disabled ET_SSL threads, so we will mark all ET_NET threads as having
+    // ET_SSL thread capabilities and just keep on chugging.
+    SSLDebug("Disabling ET_SSL threads (config is set to -1), using thread group ET_NET=%d",
ET_NET);
+    SSLNetProcessor::ET_SSL = ET_NET; // Set the event type for ET_SSL to be ET_NET.
+    return 0;
+  } else if (number_of_ssl_threads < 1) {
+    return -1;
+  }
+
   SSLNetProcessor::ET_SSL = eventProcessor.spawn_event_threads(number_of_ssl_threads, "ET_SSL",
stacksize);
   return UnixNetProcessor::start(0, stacksize);
 }

http://git-wip-us.apache.org/repos/asf/trafficserver/blob/b6c6d8de/proxy/Main.cc
----------------------------------------------------------------------
diff --git a/proxy/Main.cc b/proxy/Main.cc
index 40dfcf8..80a518a 100644
--- a/proxy/Main.cc
+++ b/proxy/Main.cc
@@ -1112,8 +1112,10 @@ getNumSSLThreads(void)
 
     REC_ReadConfigInteger(config_num_ssl_threads, "proxy.config.ssl.number.threads");
 
-    if (config_num_ssl_threads != 0) {
+    if (config_num_ssl_threads > 0) {
       num_of_ssl_threads = config_num_ssl_threads;
+    } else if (config_num_ssl_threads == -1) {
+      return -1; // This will disable ET_SSL threads entirely
     } else {
       float autoconfig_scale = 1.5;
 


Mime
View raw message