public
Description: Phusion Passenger (mod_rails)
Homepage: http://www.modrails.com/
Clone URL: git://github.com/FooBarWidget/passenger.git
Search Repo:
Click here to lend your support to: passenger and make a donation at www.pledgie.com !
Integrate the new ApplicationPoolServer implementation. Doesn't actually 
work yet.
Hongli Lai (Phusion) (author)
Wed Apr 16 14:53:40 -0700 2008
commit  629704a4b3cdae7d010419f0665a8909fcb07d1e
tree    302c26b58a9abd8d91d779da7c578ca3cfb9710a
parent  2cb15f0cb42e816bfbd5fc71789a7687a86af399
...
106
107
108
109
 
110
111
112
...
185
186
187
188
 
 
189
190
191
...
204
205
206
207
208
 
209
210
211
 
212
213
214
215
216
...
237
238
239
240
 
 
 
 
 
241
242
243
...
106
107
108
 
109
110
111
112
...
185
186
187
 
188
189
190
191
192
...
205
206
207
 
 
208
209
210
 
211
212
 
213
214
215
...
236
237
238
 
239
240
241
242
243
244
245
246
0
@@ -106,7 +106,7 @@ class APACHE2
0
     'Configuration.o' => %w(Configuration.cpp Configuration.h),
0
     'Hooks.o' => %w(Hooks.cpp Hooks.h
0
         Configuration.h ApplicationPool.h StandardApplicationPool.h
0
- ApplicationPoolClientServer.h
0
+ ApplicationPoolServer.h
0
         SpawnManager.h Exceptions.h Application.h MessageChannel.h
0
         Utils.h),
0
     'Utils.o' => %w(Utils.cpp Utils.h),
0
@@ -185,7 +185,8 @@ subdir 'ext/apache2' do
0
   
0
   desc "Remove generated files for mod_passenger Apache 2 module"
0
   task 'apache2:clean' do
0
- files = [APACHE2::OBJECTS.keys, %w(mod_passenger.o mod_passenger.so)]
0
+ files = [APACHE2::OBJECTS.keys, %w(mod_passenger.o mod_passenger.so
0
+ ApplicationPoolServerExecutable)]
0
     sh("rm", "-rf", *files.flatten)
0
   end
0
 end
0
@@ -204,13 +205,11 @@ class TEST
0
       ../ext/apache2/SpawnManager.h
0
       ../ext/apache2/Application.h),
0
     'ApplicationPoolServerTest.o' => %w(ApplicationPoolServerTest.cpp
0
- ../ext/apache2/StandardApplicationPool.h
0
- ../ext/apache2/ApplicationPoolClientServer.h),
0
+ ../ext/apache2/ApplicationPoolServer.h),
0
     'ApplicationPoolServer_ApplicationPoolTest.o' => %w(ApplicationPoolServer_ApplicationPoolTest.cpp
0
       ApplicationPoolTest.cpp
0
- ../ext/apache2/ApplicationPoolClientServer.h
0
+ ../ext/apache2/ApplicationPoolServer.h
0
       ../ext/apache2/ApplicationPool.h
0
- ../ext/apache2/StandardApplicationPool.h
0
       ../ext/apache2/SpawnManager.h
0
       ../ext/apache2/Application.h),
0
     'StandardApplicationPoolTest.o' => %w(StandardApplicationPoolTest.cpp
0
@@ -237,7 +236,11 @@ subdir 'test' do
0
   end
0
   
0
   desc "Run unit tests for the Apache 2 module in Valgrind"
0
- task 'test:valgrind' => ['Apache2ModuleTests', :native_support] do
0
+ task 'test:valgrind' => [
0
+ 'Apache2ModuleTests',
0
+ '../ext/apache2/ApplicationPoolServerExecutable',
0
+ :native_support
0
+ ] do
0
     sh "valgrind #{ENV['ARGS']} ./Apache2ModuleTests"
0
   end
0
   
...
27
28
29
 
 
30
31
32
...
36
37
38
39
 
40
41
42
...
27
28
29
30
31
32
33
34
...
38
39
40
 
41
42
43
44
0
@@ -27,6 +27,8 @@
0
 #include <apr_strings.h>
0
 #include <apr_lib.h>
0
 
0
+#include <boost/thread.hpp>
0
+
0
 #include <sys/time.h>
0
 #include <sys/resource.h>
0
 #include <exception>
0
@@ -36,7 +38,7 @@
0
 #include "Configuration.h"
0
 #include "Utils.h"
0
 #include "Logging.h"
0
-#include "ApplicationPoolClientServer.h"
0
+#include "ApplicationPoolServer.h"
0
 #include "MessageChannel.h"
0
 
0
 using namespace std;
...
1
2
 
3
4
5
...
34
35
36
37
 
 
38
39
40
...
1
 
2
3
4
5
...
34
35
36
 
37
38
39
40
41
0
@@ -1,5 +1,5 @@
0
 #include "tut.h"
0
-#include "ApplicationPoolClientServer.h"
0
+#include "ApplicationPoolServer.h"
0
 #include "Utils.h"
0
 #include <cstring>
0
 #include <unistd.h>
0
@@ -34,7 +34,8 @@ namespace tut {
0
         initialFileDescriptors = countOpenFileDescriptors();
0
         firstRun = false;
0
       }
0
- server = ptr(new ApplicationPoolServer("stub/spawn_server.rb"));
0
+ server = ptr(new ApplicationPoolServer("../ext/apache2/ApplicationPoolServerExecutable",
0
+ "stub/spawn_server.rb"));
0
     }
0
     
0
     
...
1
2
 
 
3
4
 
5
6
7
...
9
10
11
12
 
 
 
13
14
15
...
1
 
2
3
4
5
6
7
8
9
...
11
12
13
 
14
15
16
17
18
19
0
@@ -1,7 +1,9 @@
0
 #include "tut.h"
0
-#include "ApplicationPoolClientServer.h"
0
+#include <boost/thread.hpp>
0
+#include "ApplicationPoolServer.h"
0
 
0
 using namespace Passenger;
0
+using namespace boost;
0
 
0
 namespace tut {
0
   struct ApplicationPoolServer_ApplicationPoolTest {
0
@@ -9,7 +11,9 @@ namespace tut {
0
     ApplicationPoolPtr pool, pool2;
0
     
0
     ApplicationPoolServer_ApplicationPoolTest() {
0
- server = ptr(new ApplicationPoolServer("../bin/passenger-spawn-server"));
0
+ server = ptr(new ApplicationPoolServer(
0
+ "../ext/apache2/ApplicationPoolServerExecutable",
0
+ "../bin/passenger-spawn-server"));
0
       pool = server->connect();
0
       pool2 = server->connect();
0
     }
...
5
6
7
8
9
10
11
12
13
...
5
6
7
 
 
 
8
9
10
0
@@ -5,9 +5,6 @@
0
 #include <cstdlib>
0
 #include <cerrno>
0
 #include <signal.h>
0
-#include <boost/thread.hpp>
0
-
0
-using namespace boost;
0
 
0
 /**
0
  * This file is used as a template to test the different ApplicationPool implementations.

Comments

    No one has commented yet.