You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by jp...@apache.org on 2012/02/19 17:47:50 UTC

[2/5] git commit: TS-841: Load plugins after opening sockets

TS-841: Load plugins after opening sockets

Load plugins after opening the configured listen ports. We need to
do this so that the ports are there when we register NPN names on
them.


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

Branch: refs/heads/master
Commit: b282375a845df54e5eed6fe60a05a9918b2724c8
Parents: 115434b
Author: James Peach <jp...@apache.org>
Authored: Fri Feb 17 21:36:36 2012 -0800
Committer: James Peach <jp...@apache.org>
Committed: Sun Feb 19 08:46:08 2012 -0800

----------------------------------------------------------------------
 proxy/Main.cc |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/b282375a/proxy/Main.cc
----------------------------------------------------------------------
diff --git a/proxy/Main.cc b/proxy/Main.cc
index 73f2598..7f0b412 100644
--- a/proxy/Main.cc
+++ b/proxy/Main.cc
@@ -1762,14 +1762,6 @@ main(int argc, char **argv)
     // main server logic initiated here //
     //////////////////////////////////////
 
-#ifndef TS_NO_API
-    plugin_init(system_config_directory, false);        // plugin.config
-#else
-    api_init();                 // we still need to initialize some of the data structure other module needs.
-    extern void init_inkapi_stat_system();
-    init_inkapi_stat_system();
-    // i.e. http_global_hooks
-#endif
 #ifndef TS_NO_TRANSFORM
     transformProcessor.start();
 #endif
@@ -1790,6 +1782,15 @@ main(int argc, char **argv)
 #endif
     }
 
+#ifndef TS_NO_API
+    plugin_init(system_config_directory, false);        // plugin.config
+#else
+    api_init();                 // we still need to initialize some of the data structure other module needs.
+    extern void init_inkapi_stat_system();
+    init_inkapi_stat_system();
+    // i.e. http_global_hooks
+#endif
+
     // "Task" processor, possibly with its own set of task threads
     tasksProcessor.start(num_task_threads);