passenger 2.2.1 → 2.2.2

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of passenger might be problematic. Click here for more details.

Files changed (216) hide show
  1. data/Rakefile +66 -79
  2. data/bin/passenger-install-nginx-module +1 -1
  3. data/bin/passenger-memory-stats +1 -1
  4. data/bin/passenger-spawn-server +8 -2
  5. data/doc/Users guide Apache.html +33 -49
  6. data/doc/Users guide Apache.txt +28 -27
  7. data/doc/Users guide Nginx.html +9 -19
  8. data/doc/Users guide Nginx.txt +8 -20
  9. data/doc/cxxapi/Bucket_8h-source.html +1 -1
  10. data/doc/cxxapi/Configuration_8h-source.html +297 -300
  11. data/doc/cxxapi/DirectoryMapper_8h-source.html +1 -1
  12. data/doc/cxxapi/Hooks_8h-source.html +1 -1
  13. data/doc/cxxapi/annotated.html +1 -1
  14. data/doc/cxxapi/classHooks-members.html +1 -1
  15. data/doc/cxxapi/classHooks.html +1 -1
  16. data/doc/cxxapi/classPassenger_1_1DirectoryMapper-members.html +1 -1
  17. data/doc/cxxapi/classPassenger_1_1DirectoryMapper.html +1 -1
  18. data/doc/cxxapi/classes.html +1 -1
  19. data/doc/cxxapi/definitions_8h-source.html +1 -1
  20. data/doc/cxxapi/files.html +1 -1
  21. data/doc/cxxapi/functions.html +1 -1
  22. data/doc/cxxapi/functions_func.html +1 -1
  23. data/doc/cxxapi/graph_legend.html +1 -1
  24. data/doc/cxxapi/group__Configuration.html +1 -23
  25. data/doc/cxxapi/group__Core.html +1 -1
  26. data/doc/cxxapi/group__Hooks.html +1 -1
  27. data/doc/cxxapi/group__Support.html +1 -1
  28. data/doc/cxxapi/main.html +1 -1
  29. data/doc/cxxapi/modules.html +1 -1
  30. data/doc/users_guide_snippets/rackup_specifications.txt +4 -2
  31. data/ext/apache2/Configuration.h +0 -3
  32. data/ext/apache2/Hooks.cpp +5 -3
  33. data/ext/common/ApplicationPoolServer.h +1 -0
  34. data/ext/common/ApplicationPoolServerExecutable.cpp +5 -2
  35. data/ext/common/SpawnManager.h +1 -0
  36. data/ext/common/Utils.cpp +22 -23
  37. data/ext/common/Utils.h +32 -21
  38. data/ext/common/Version.h +31 -0
  39. data/ext/nginx/ContentHandler.c +61 -8
  40. data/ext/nginx/HelperServer.cpp +3 -0
  41. data/ext/nginx/HttpStatusExtractor.h +185 -0
  42. data/ext/nginx/StaticContentHandler.c +18 -3
  43. data/ext/nginx/config +2 -1
  44. data/ext/nginx/ngx_http_passenger_module.c +21 -15
  45. data/ext/oxt/backtrace.cpp +4 -2
  46. data/ext/oxt/spin_lock.hpp +3 -3
  47. data/lib/phusion_passenger/abstract_request_handler.rb +5 -3
  48. data/lib/phusion_passenger/admin_tools/control_process.rb +6 -1
  49. data/lib/phusion_passenger/constants.rb +2 -2
  50. data/lib/phusion_passenger/rack/application_spawner.rb +2 -1
  51. data/lib/phusion_passenger/rack/request_handler.rb +45 -35
  52. data/lib/phusion_passenger/templates/nginx/config_snippets.txt.erb +1 -1
  53. data/lib/phusion_passenger/utils.rb +13 -3
  54. data/misc/rake/cplusplus.rb +7 -0
  55. data/test/ApplicationPoolServer_ApplicationPoolTest.cpp +2 -0
  56. data/test/ApplicationPoolTest.cpp +39 -62
  57. data/test/CxxTestMain.cpp +6 -6
  58. data/test/HttpStatusExtractorTest.cpp +17 -0
  59. data/test/StandardApplicationPoolTest.cpp +2 -0
  60. data/test/UtilsTest.cpp +17 -28
  61. data/test/ruby/abstract_request_handler_spec.rb +3 -7
  62. data/test/ruby/utils_spec.rb +18 -13
  63. data/test/ruby/wsgi/application_spawner_spec.rb +5 -9
  64. data/test/stub/railsapp/app/controllers/{bar_controller_1.rb → bar_controller.rb} +0 -0
  65. data/test/stub/railsapp/app/controllers/bar_controller_1.txt +5 -0
  66. data/test/stub/railsapp/app/controllers/{bar_controller_2.rb → bar_controller_2.txt} +0 -0
  67. data/test/support/Support.h +20 -0
  68. data/test/support/config.rb +13 -0
  69. data/vendor/README +4 -3
  70. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/COPYING +1 -1
  71. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/KNOWN-ISSUES +0 -0
  72. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/README +54 -7
  73. data/vendor/rack-1.0.0-git/Rakefile +164 -0
  74. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack.rb +7 -3
  75. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/adapter/camping.rb +0 -0
  76. data/vendor/rack-1.0.0-git/lib/rack/auth/abstract/handler.rb +37 -0
  77. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/auth/abstract/request.rb +0 -0
  78. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/auth/basic.rb +0 -0
  79. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/auth/digest/md5.rb +1 -1
  80. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/auth/digest/nonce.rb +0 -0
  81. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/auth/digest/params.rb +0 -0
  82. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/auth/digest/request.rb +2 -2
  83. data/vendor/rack-1.0.0-git/lib/rack/auth/openid.rb +480 -0
  84. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/builder.rb +1 -5
  85. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/cascade.rb +0 -0
  86. data/vendor/rack-1.0.0-git/lib/rack/chunked.rb +49 -0
  87. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/commonlogger.rb +0 -0
  88. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/conditionalget.rb +4 -0
  89. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/content_length.rb +7 -3
  90. data/vendor/rack-1.0.0-git/lib/rack/content_type.rb +23 -0
  91. data/vendor/rack-1.0.0-git/lib/rack/deflater.rb +96 -0
  92. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/directory.rb +5 -2
  93. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/file.rb +4 -1
  94. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler.rb +22 -1
  95. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/cgi.rb +7 -3
  96. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/evented_mongrel.rb +0 -0
  97. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/fastcgi.rb +26 -24
  98. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/lsws.rb +7 -4
  99. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/mongrel.rb +5 -3
  100. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/scgi.rb +5 -3
  101. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/swiftiplied_mongrel.rb +0 -0
  102. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/thin.rb +3 -0
  103. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/handler/webrick.rb +11 -5
  104. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/head.rb +0 -0
  105. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/lint.rb +138 -66
  106. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/lobster.rb +0 -0
  107. data/vendor/rack-1.0.0-git/lib/rack/lock.rb +16 -0
  108. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/methodoverride.rb +0 -0
  109. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/mime.rb +4 -4
  110. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/mock.rb +42 -5
  111. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/recursive.rb +0 -0
  112. data/vendor/rack-1.0.0-git/lib/rack/reloader.rb +106 -0
  113. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/request.rb +46 -10
  114. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/response.rb +15 -3
  115. data/vendor/rack-1.0.0-git/lib/rack/rewindable_input.rb +98 -0
  116. data/vendor/rack-1.0.0-git/lib/rack/session/abstract/id.rb +142 -0
  117. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/session/cookie.rb +2 -0
  118. data/vendor/rack-1.0.0-git/lib/rack/session/memcache.rb +109 -0
  119. data/vendor/rack-1.0.0-git/lib/rack/session/pool.rb +100 -0
  120. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/showexceptions.rb +2 -1
  121. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/showstatus.rb +1 -1
  122. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/static.rb +0 -0
  123. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/urlmap.rb +12 -5
  124. data/vendor/{rack-0.9.1 → rack-1.0.0-git}/lib/rack/utils.rb +212 -65
  125. metadata +71 -170
  126. data/doc/rdoc/classes/ConditionVariable.html +0 -194
  127. data/doc/rdoc/classes/Exception.html +0 -120
  128. data/doc/rdoc/classes/GC.html +0 -113
  129. data/doc/rdoc/classes/IO.html +0 -169
  130. data/doc/rdoc/classes/PhusionPassenger.html +0 -238
  131. data/doc/rdoc/classes/PhusionPassenger/AbstractInstaller.html +0 -153
  132. data/doc/rdoc/classes/PhusionPassenger/AbstractRequestHandler.html +0 -506
  133. data/doc/rdoc/classes/PhusionPassenger/AbstractServer.html +0 -692
  134. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/ServerAlreadyStarted.html +0 -97
  135. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/ServerError.html +0 -96
  136. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/ServerNotStarted.html +0 -97
  137. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/UnknownMessage.html +0 -96
  138. data/doc/rdoc/classes/PhusionPassenger/AbstractServerCollection.html +0 -598
  139. data/doc/rdoc/classes/PhusionPassenger/AdminTools.html +0 -140
  140. data/doc/rdoc/classes/PhusionPassenger/AdminTools/ControlProcess.html +0 -264
  141. data/doc/rdoc/classes/PhusionPassenger/AdminTools/ControlProcess/Instance.html +0 -138
  142. data/doc/rdoc/classes/PhusionPassenger/AppInitError.html +0 -154
  143. data/doc/rdoc/classes/PhusionPassenger/Application.html +0 -283
  144. data/doc/rdoc/classes/PhusionPassenger/ConsoleTextTemplate.html +0 -172
  145. data/doc/rdoc/classes/PhusionPassenger/FrameworkInitError.html +0 -145
  146. data/doc/rdoc/classes/PhusionPassenger/HTMLTemplate.html +0 -175
  147. data/doc/rdoc/classes/PhusionPassenger/InitializationError.html +0 -141
  148. data/doc/rdoc/classes/PhusionPassenger/InvalidPath.html +0 -92
  149. data/doc/rdoc/classes/PhusionPassenger/MessageChannel.html +0 -489
  150. data/doc/rdoc/classes/PhusionPassenger/NativeSupport.html +0 -350
  151. data/doc/rdoc/classes/PhusionPassenger/Rack.html +0 -91
  152. data/doc/rdoc/classes/PhusionPassenger/Rack/ApplicationSpawner.html +0 -185
  153. data/doc/rdoc/classes/PhusionPassenger/Rack/RequestHandler.html +0 -184
  154. data/doc/rdoc/classes/PhusionPassenger/Railz.html +0 -95
  155. data/doc/rdoc/classes/PhusionPassenger/Railz/ApplicationSpawner.html +0 -419
  156. data/doc/rdoc/classes/PhusionPassenger/Railz/ApplicationSpawner/Error.html +0 -98
  157. data/doc/rdoc/classes/PhusionPassenger/Railz/CGIFixed.html +0 -200
  158. data/doc/rdoc/classes/PhusionPassenger/Railz/FrameworkSpawner.html +0 -443
  159. data/doc/rdoc/classes/PhusionPassenger/Railz/FrameworkSpawner/Error.html +0 -98
  160. data/doc/rdoc/classes/PhusionPassenger/Railz/RequestHandler.html +0 -154
  161. data/doc/rdoc/classes/PhusionPassenger/SpawnManager.html +0 -402
  162. data/doc/rdoc/classes/PhusionPassenger/UnknownError.html +0 -125
  163. data/doc/rdoc/classes/PhusionPassenger/Utils.html +0 -694
  164. data/doc/rdoc/classes/PhusionPassenger/VersionNotFound.html +0 -140
  165. data/doc/rdoc/classes/PhusionPassenger/WSGI.html +0 -89
  166. data/doc/rdoc/classes/PhusionPassenger/WSGI/ApplicationSpawner.html +0 -188
  167. data/doc/rdoc/classes/PlatformInfo.html +0 -831
  168. data/doc/rdoc/classes/RakeExtensions.html +0 -197
  169. data/doc/rdoc/classes/Signal.html +0 -134
  170. data/doc/rdoc/created.rid +0 -1
  171. data/doc/rdoc/files/DEVELOPERS_TXT.html +0 -240
  172. data/doc/rdoc/files/README.html +0 -157
  173. data/doc/rdoc/files/ext/phusion_passenger/native_support_c.html +0 -92
  174. data/doc/rdoc/files/lib/phusion_passenger/abstract_installer_rb.html +0 -129
  175. data/doc/rdoc/files/lib/phusion_passenger/abstract_request_handler_rb.html +0 -131
  176. data/doc/rdoc/files/lib/phusion_passenger/abstract_server_collection_rb.html +0 -126
  177. data/doc/rdoc/files/lib/phusion_passenger/abstract_server_rb.html +0 -130
  178. data/doc/rdoc/files/lib/phusion_passenger/admin_tools/control_process_rb.html +0 -129
  179. data/doc/rdoc/files/lib/phusion_passenger/admin_tools_rb.html +0 -122
  180. data/doc/rdoc/files/lib/phusion_passenger/application_rb.html +0 -127
  181. data/doc/rdoc/files/lib/phusion_passenger/console_text_template_rb.html +0 -126
  182. data/doc/rdoc/files/lib/phusion_passenger/constants_rb.html +0 -122
  183. data/doc/rdoc/files/lib/phusion_passenger/dependencies_rb.html +0 -134
  184. data/doc/rdoc/files/lib/phusion_passenger/events_rb.html +0 -122
  185. data/doc/rdoc/files/lib/phusion_passenger/exceptions_rb.html +0 -122
  186. data/doc/rdoc/files/lib/phusion_passenger/html_template_rb.html +0 -126
  187. data/doc/rdoc/files/lib/phusion_passenger/message_channel_rb.html +0 -122
  188. data/doc/rdoc/files/lib/phusion_passenger/packaging_rb.html +0 -122
  189. data/doc/rdoc/files/lib/phusion_passenger/platform_info_rb.html +0 -127
  190. data/doc/rdoc/files/lib/phusion_passenger/rack/application_spawner_rb.html +0 -133
  191. data/doc/rdoc/files/lib/phusion_passenger/rack/request_handler_rb.html +0 -126
  192. data/doc/rdoc/files/lib/phusion_passenger/railz/application_spawner_rb.html +0 -143
  193. data/doc/rdoc/files/lib/phusion_passenger/railz/cgi_fixed_rb.html +0 -126
  194. data/doc/rdoc/files/lib/phusion_passenger/railz/framework_spawner_rb.html +0 -145
  195. data/doc/rdoc/files/lib/phusion_passenger/railz/request_handler_rb.html +0 -127
  196. data/doc/rdoc/files/lib/phusion_passenger/simple_benchmarking_rb.html +0 -122
  197. data/doc/rdoc/files/lib/phusion_passenger/spawn_manager_rb.html +0 -161
  198. data/doc/rdoc/files/lib/phusion_passenger/utils_rb.html +0 -175
  199. data/doc/rdoc/files/lib/phusion_passenger/wsgi/application_spawner_rb.html +0 -129
  200. data/doc/rdoc/files/misc/rake/extensions_rb.html +0 -130
  201. data/doc/rdoc/fr_class_index.html +0 -90
  202. data/doc/rdoc/fr_file_index.html +0 -76
  203. data/doc/rdoc/fr_method_index.html +0 -195
  204. data/doc/rdoc/index.html +0 -26
  205. data/doc/rdoc/rdoc-style.css +0 -187
  206. data/vendor/rack-0.9.1/AUTHORS +0 -8
  207. data/vendor/rack-0.9.1/ChangeLog +0 -1423
  208. data/vendor/rack-0.9.1/Rakefile +0 -188
  209. data/vendor/rack-0.9.1/SPEC +0 -129
  210. data/vendor/rack-0.9.1/lib/rack/auth/abstract/handler.rb +0 -28
  211. data/vendor/rack-0.9.1/lib/rack/auth/openid.rb +0 -438
  212. data/vendor/rack-0.9.1/lib/rack/deflater.rb +0 -87
  213. data/vendor/rack-0.9.1/lib/rack/reloader.rb +0 -64
  214. data/vendor/rack-0.9.1/lib/rack/session/abstract/id.rb +0 -153
  215. data/vendor/rack-0.9.1/lib/rack/session/memcache.rb +0 -97
  216. data/vendor/rack-0.9.1/lib/rack/session/pool.rb +0 -73
@@ -1,140 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
- <html>
6
- <head>
7
- <title>Module: PhusionPassenger::AdminTools</title>
8
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
9
- <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
10
-
11
- <script language="JavaScript" type="text/javascript">
12
- // <![CDATA[
13
-
14
- function toggleSource( id )
15
- {
16
- var elem
17
- var link
18
-
19
- if( document.getElementById )
20
- {
21
- elem = document.getElementById( id )
22
- link = document.getElementById( "l_" + id )
23
- }
24
- else if ( document.all )
25
- {
26
- elem = eval( "document.all." + id )
27
- link = eval( "document.all.l_" + id )
28
- }
29
- else
30
- return false;
31
-
32
- if( elem.style.display == "block" )
33
- {
34
- elem.style.display = "none"
35
- link.innerHTML = "show source"
36
- }
37
- else
38
- {
39
- elem.style.display = "block"
40
- link.innerHTML = "hide source"
41
- }
42
- }
43
-
44
- function openCode( url )
45
- {
46
- window.open( url, "SOURCE_CODE", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=480,width=750" ).focus();
47
- }
48
- // ]]>
49
- </script>
50
- </head>
51
-
52
- <body>
53
- <table width="100%" border='0' cellpadding='0' cellspacing='0' class='banner'><tr>
54
- <td class="file-title"><span class="file-title-prefix">Module</span><br />PhusionPassenger::AdminTools</td>
55
- <td align="right">
56
- <table cellspacing="0" cellpadding="2">
57
- <tr valign="top">
58
- <td>In:</td>
59
- <td>
60
- <a href="../../files/lib/phusion_passenger/admin_tools_rb.html">lib/phusion_passenger/admin_tools.rb</a>
61
- <a href="../../files/lib/phusion_passenger/admin_tools/control_process_rb.html">lib/phusion_passenger/admin_tools/control_process.rb</a>
62
- </td>
63
- </tr>
64
- </table>
65
- </td>
66
- </tr>
67
- </table>
68
- <!-- banner header -->
69
-
70
- <div id="bodyContent">
71
- <div id="content">
72
-
73
-
74
-
75
-
76
- <div class="sectiontitle">Methods</div>
77
- <ul>
78
- <li><a href="#M000065">process_is_alive?</a></li>
79
- <li><a href="#M000064">tmpdir</a></li>
80
- </ul>
81
-
82
-
83
-
84
- <div class="sectiontitle">Classes and Modules</div>
85
- Class <a href="AdminTools/ControlProcess.html" class="link">PhusionPassenger::AdminTools::ControlProcess</a><br />
86
-
87
-
88
-
89
-
90
- <div class="sectiontitle">Public Class methods</div>
91
- <div class="method">
92
- <div class="title">
93
- <a name="M000065"></a><b>process_is_alive?</b>(pid)
94
- </div>
95
- <div class="sourcecode">
96
- <p class="source-link">[ <a href="javascript:toggleSource('M000065_source')" id="l_M000065_source">show source</a> ]</p>
97
- <div id="M000065_source" class="dyn-source">
98
- <pre>
99
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools.rb, line 36</span>
100
- 36: <span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">process_is_alive?</span>(<span class="ruby-identifier">pid</span>)
101
- 37: <span class="ruby-keyword kw">begin</span>
102
- 38: <span class="ruby-constant">Process</span>.<span class="ruby-identifier">kill</span>(<span class="ruby-value">0</span>, <span class="ruby-identifier">pid</span>)
103
- 39: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">true</span>
104
- 40: <span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">Errno</span><span class="ruby-operator">::</span><span class="ruby-constant">ESRCH</span>
105
- 41: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">false</span>
106
- 42: <span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">SystemCallError</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-identifier">e</span>
107
- 43: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">true</span>
108
- 44: <span class="ruby-keyword kw">end</span>
109
- 45: <span class="ruby-keyword kw">end</span>
110
- </pre>
111
- </div>
112
- </div>
113
- </div>
114
- <div class="method">
115
- <div class="title">
116
- <a name="M000064"></a><b>tmpdir</b>()
117
- </div>
118
- <div class="sourcecode">
119
- <p class="source-link">[ <a href="javascript:toggleSource('M000064_source')" id="l_M000064_source">show source</a> ]</p>
120
- <div id="M000064_source" class="dyn-source">
121
- <pre>
122
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools.rb, line 27</span>
123
- 27: <span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">tmpdir</span>
124
- 28: [<span class="ruby-value str">&quot;PASSENGER_TEMP_DIR&quot;</span>, <span class="ruby-value str">&quot;PASSENGER_TMPDIR&quot;</span>].<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">name</span><span class="ruby-operator">|</span>
125
- 29: <span class="ruby-keyword kw">if</span> <span class="ruby-constant">ENV</span>.<span class="ruby-identifier">has_key?</span>(<span class="ruby-identifier">name</span>) <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-operator">!</span><span class="ruby-constant">ENV</span>[<span class="ruby-identifier">name</span>].<span class="ruby-identifier">empty?</span>
126
- 30: <span class="ruby-keyword kw">return</span> <span class="ruby-constant">ENV</span>[<span class="ruby-identifier">name</span>]
127
- 31: <span class="ruby-keyword kw">end</span>
128
- 32: <span class="ruby-keyword kw">end</span>
129
- 33: <span class="ruby-keyword kw">return</span> <span class="ruby-value str">&quot;/tmp&quot;</span>
130
- 34: <span class="ruby-keyword kw">end</span>
131
- </pre>
132
- </div>
133
- </div>
134
- </div>
135
- </div>
136
-
137
- </div>
138
-
139
- </body>
140
- </html>
@@ -1,264 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
- <html>
6
- <head>
7
- <title>Class: PhusionPassenger::AdminTools::ControlProcess</title>
8
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
9
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
10
-
11
- <script language="JavaScript" type="text/javascript">
12
- // <![CDATA[
13
-
14
- function toggleSource( id )
15
- {
16
- var elem
17
- var link
18
-
19
- if( document.getElementById )
20
- {
21
- elem = document.getElementById( id )
22
- link = document.getElementById( "l_" + id )
23
- }
24
- else if ( document.all )
25
- {
26
- elem = eval( "document.all." + id )
27
- link = eval( "document.all.l_" + id )
28
- }
29
- else
30
- return false;
31
-
32
- if( elem.style.display == "block" )
33
- {
34
- elem.style.display = "none"
35
- link.innerHTML = "show source"
36
- }
37
- else
38
- {
39
- elem.style.display = "block"
40
- link.innerHTML = "hide source"
41
- }
42
- }
43
-
44
- function openCode( url )
45
- {
46
- window.open( url, "SOURCE_CODE", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=480,width=750" ).focus();
47
- }
48
- // ]]>
49
- </script>
50
- </head>
51
-
52
- <body>
53
- <table width="100%" border='0' cellpadding='0' cellspacing='0' class='banner'><tr>
54
- <td class="file-title"><span class="file-title-prefix">Class</span><br />PhusionPassenger::AdminTools::ControlProcess</td>
55
- <td align="right">
56
- <table cellspacing="0" cellpadding="2">
57
- <tr valign="top">
58
- <td>In:</td>
59
- <td>
60
- <a href="../../../files/lib/phusion_passenger/admin_tools/control_process_rb.html">lib/phusion_passenger/admin_tools/control_process.rb</a>
61
- </td>
62
- </tr>
63
- <tr>
64
- <td>Parent:</td>
65
- <td>
66
- Object
67
- </td>
68
- </tr>
69
- </table>
70
- </td>
71
- </tr>
72
- </table>
73
- <!-- banner header -->
74
-
75
- <div id="bodyContent">
76
- <div id="content">
77
-
78
-
79
-
80
-
81
- <div class="sectiontitle">Methods</div>
82
- <ul>
83
- <li><a href="#M000071">domains</a></li>
84
- <li><a href="#M000067">for_pid</a></li>
85
- <li><a href="#M000072">instances</a></li>
86
- <li><a href="#M000066">list</a></li>
87
- <li><a href="#M000068">new</a></li>
88
- <li><a href="#M000069">status</a></li>
89
- <li><a href="#M000070">xml</a></li>
90
- </ul>
91
-
92
-
93
-
94
- <div class="sectiontitle">Classes and Modules</div>
95
- Class <a href="ControlProcess/Instance.html" class="link">PhusionPassenger::AdminTools::ControlProcess::Instance</a><br />
96
-
97
-
98
-
99
- <div class="sectiontitle">Attributes</div>
100
- <table border='0' cellpadding='5'>
101
- <tr valign='top'>
102
- <td class='attr-rw'>
103
- [RW]
104
- </td>
105
- <td class='attr-name'>path</td>
106
- <td class='attr-desc'></td>
107
- </tr>
108
- <tr valign='top'>
109
- <td class='attr-rw'>
110
- [RW]
111
- </td>
112
- <td class='attr-name'>pid</td>
113
- <td class='attr-desc'></td>
114
- </tr>
115
- </table>
116
-
117
- <div class="sectiontitle">Public Class methods</div>
118
- <div class="method">
119
- <div class="title">
120
- <a name="M000067"></a><b>for_pid</b>(pid)
121
- </div>
122
- <div class="sourcecode">
123
- <p class="source-link">[ <a href="javascript:toggleSource('M000067_source')" id="l_M000067_source">show source</a> ]</p>
124
- <div id="M000067_source" class="dyn-source">
125
- <pre>
126
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools/control_process.rb, line 59</span>
127
- 59: <span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">for_pid</span>(<span class="ruby-identifier">pid</span>)
128
- 60: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">list</span>(<span class="ruby-keyword kw">false</span>).<span class="ruby-identifier">find</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">c</span><span class="ruby-operator">|</span> <span class="ruby-identifier">c</span>.<span class="ruby-identifier">pid</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">pid</span> }
129
- 61: <span class="ruby-keyword kw">end</span>
130
- </pre>
131
- </div>
132
- </div>
133
- </div>
134
- <div class="method">
135
- <div class="title">
136
- <a name="M000066"></a><b>list</b>(clean_stale = true)
137
- </div>
138
- <div class="sourcecode">
139
- <p class="source-link">[ <a href="javascript:toggleSource('M000066_source')" id="l_M000066_source">show source</a> ]</p>
140
- <div id="M000066_source" class="dyn-source">
141
- <pre>
142
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools/control_process.rb, line 41</span>
143
- 41: <span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">list</span>(<span class="ruby-identifier">clean_stale</span> = <span class="ruby-keyword kw">true</span>)
144
- 42: <span class="ruby-identifier">results</span> = []
145
- 43: <span class="ruby-constant">Dir</span>[<span class="ruby-node">&quot;#{AdminTools.tmpdir}/passenger.*&quot;</span>].<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">dir</span><span class="ruby-operator">|</span>
146
- 44: <span class="ruby-keyword kw">next</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">dir</span> <span class="ruby-operator">!~</span> <span class="ruby-regexp re">/passenger.(\d+)\Z/</span>
147
- 45: <span class="ruby-keyword kw">begin</span>
148
- 46: <span class="ruby-identifier">results</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-constant">ControlProcess</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">dir</span>)
149
- 47: <span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">ArgumentError</span>
150
- 48: <span class="ruby-comment cmt"># Stale Passenger temp folder. Clean it up if instructed.</span>
151
- 49: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">clean_stale</span>
152
- 50: <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;*** Cleaning stale folder #{dir}&quot;</span>
153
- 51: <span class="ruby-constant">FileUtils</span>.<span class="ruby-identifier">chmod_R</span>(<span class="ruby-value">0700</span>, <span class="ruby-identifier">dir</span>) <span class="ruby-keyword kw">rescue</span> <span class="ruby-keyword kw">nil</span>
154
- 52: <span class="ruby-constant">FileUtils</span>.<span class="ruby-identifier">rm_rf</span>(<span class="ruby-identifier">dir</span>)
155
- 53: <span class="ruby-keyword kw">end</span>
156
- 54: <span class="ruby-keyword kw">end</span>
157
- 55: <span class="ruby-keyword kw">end</span>
158
- 56: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">results</span>
159
- 57: <span class="ruby-keyword kw">end</span>
160
- </pre>
161
- </div>
162
- </div>
163
- </div>
164
- <div class="method">
165
- <div class="title">
166
- <a name="M000068"></a><b>new</b>(path)
167
- </div>
168
- <div class="sourcecode">
169
- <p class="source-link">[ <a href="javascript:toggleSource('M000068_source')" id="l_M000068_source">show source</a> ]</p>
170
- <div id="M000068_source" class="dyn-source">
171
- <pre>
172
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools/control_process.rb, line 63</span>
173
- 63: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">path</span>)
174
- 64: <span class="ruby-ivar">@path</span> = <span class="ruby-identifier">path</span>
175
- 65: <span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-node">&quot;#{path}/control_process.pid&quot;</span>)
176
- 66: <span class="ruby-ivar">@pid</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">read</span>(<span class="ruby-node">&quot;#{path}/control_process.pid&quot;</span>).<span class="ruby-identifier">strip</span>.<span class="ruby-identifier">to_i</span>
177
- 67: <span class="ruby-keyword kw">else</span>
178
- 68: <span class="ruby-identifier">path</span> <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/passenger.(\d+)\Z/</span>
179
- 69: <span class="ruby-ivar">@pid</span> = <span class="ruby-identifier">$1</span>.<span class="ruby-identifier">to_i</span>
180
- 70: <span class="ruby-keyword kw">end</span>
181
- 71: <span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span><span class="ruby-constant">AdminTools</span>.<span class="ruby-identifier">process_is_alive?</span>(<span class="ruby-ivar">@pid</span>)
182
- 72: <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-node">&quot;There is no control process with PID #{@pid}.&quot;</span>
183
- 73: <span class="ruby-keyword kw">end</span>
184
- 74: <span class="ruby-keyword kw">end</span>
185
- </pre>
186
- </div>
187
- </div>
188
- </div>
189
- <div class="sectiontitle">Public Instance methods</div>
190
- <div class="method">
191
- <div class="title">
192
- <a name="M000071"></a><b>domains</b>()
193
- </div>
194
- <div class="sourcecode">
195
- <p class="source-link">[ <a href="javascript:toggleSource('M000071_source')" id="l_M000071_source">show source</a> ]</p>
196
- <div id="M000071_source" class="dyn-source">
197
- <pre>
198
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools/control_process.rb, line 86</span>
199
- 86: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domains</span>
200
- 87: <span class="ruby-identifier">reload</span>
201
- 88: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@domains</span>
202
- 89: <span class="ruby-keyword kw">end</span>
203
- </pre>
204
- </div>
205
- </div>
206
- </div>
207
- <div class="method">
208
- <div class="title">
209
- <a name="M000072"></a><b>instances</b>()
210
- </div>
211
- <div class="sourcecode">
212
- <p class="source-link">[ <a href="javascript:toggleSource('M000072_source')" id="l_M000072_source">show source</a> ]</p>
213
- <div id="M000072_source" class="dyn-source">
214
- <pre>
215
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools/control_process.rb, line 91</span>
216
- 91: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">instances</span>
217
- 92: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">domains</span>.<span class="ruby-identifier">map</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">domain</span><span class="ruby-operator">|</span>
218
- 93: <span class="ruby-identifier">domain</span>[<span class="ruby-identifier">:instances</span>]
219
- 94: <span class="ruby-keyword kw">end</span>.<span class="ruby-identifier">flatten</span>
220
- 95: <span class="ruby-keyword kw">end</span>
221
- </pre>
222
- </div>
223
- </div>
224
- </div>
225
- <div class="method">
226
- <div class="title">
227
- <a name="M000069"></a><b>status</b>()
228
- </div>
229
- <div class="sourcecode">
230
- <p class="source-link">[ <a href="javascript:toggleSource('M000069_source')" id="l_M000069_source">show source</a> ]</p>
231
- <div id="M000069_source" class="dyn-source">
232
- <pre>
233
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools/control_process.rb, line 76</span>
234
- 76: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">status</span>
235
- 77: <span class="ruby-identifier">reload</span>
236
- 78: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@status</span>
237
- 79: <span class="ruby-keyword kw">end</span>
238
- </pre>
239
- </div>
240
- </div>
241
- </div>
242
- <div class="method">
243
- <div class="title">
244
- <a name="M000070"></a><b>xml</b>()
245
- </div>
246
- <div class="sourcecode">
247
- <p class="source-link">[ <a href="javascript:toggleSource('M000070_source')" id="l_M000070_source">show source</a> ]</p>
248
- <div id="M000070_source" class="dyn-source">
249
- <pre>
250
- <span class="ruby-comment cmt"># File lib/phusion_passenger/admin_tools/control_process.rb, line 81</span>
251
- 81: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">xml</span>
252
- 82: <span class="ruby-identifier">reload</span>
253
- 83: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@xml</span>
254
- 84: <span class="ruby-keyword kw">end</span>
255
- </pre>
256
- </div>
257
- </div>
258
- </div>
259
- </div>
260
-
261
- </div>
262
-
263
- </body>
264
- </html>
@@ -1,138 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
- <html>
6
- <head>
7
- <title>Class: PhusionPassenger::AdminTools::ControlProcess::Instance</title>
8
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
9
- <link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
10
-
11
- <script language="JavaScript" type="text/javascript">
12
- // <![CDATA[
13
-
14
- function toggleSource( id )
15
- {
16
- var elem
17
- var link
18
-
19
- if( document.getElementById )
20
- {
21
- elem = document.getElementById( id )
22
- link = document.getElementById( "l_" + id )
23
- }
24
- else if ( document.all )
25
- {
26
- elem = eval( "document.all." + id )
27
- link = eval( "document.all.l_" + id )
28
- }
29
- else
30
- return false;
31
-
32
- if( elem.style.display == "block" )
33
- {
34
- elem.style.display = "none"
35
- link.innerHTML = "show source"
36
- }
37
- else
38
- {
39
- elem.style.display = "block"
40
- link.innerHTML = "hide source"
41
- }
42
- }
43
-
44
- function openCode( url )
45
- {
46
- window.open( url, "SOURCE_CODE", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=480,width=750" ).focus();
47
- }
48
- // ]]>
49
- </script>
50
- </head>
51
-
52
- <body>
53
- <table width="100%" border='0' cellpadding='0' cellspacing='0' class='banner'><tr>
54
- <td class="file-title"><span class="file-title-prefix">Class</span><br />PhusionPassenger::AdminTools::ControlProcess::Instance</td>
55
- <td align="right">
56
- <table cellspacing="0" cellpadding="2">
57
- <tr valign="top">
58
- <td>In:</td>
59
- <td>
60
- <a href="../../../../files/lib/phusion_passenger/admin_tools/control_process_rb.html">lib/phusion_passenger/admin_tools/control_process.rb</a>
61
- </td>
62
- </tr>
63
- <tr>
64
- <td>Parent:</td>
65
- <td>
66
- Object
67
- </td>
68
- </tr>
69
- </table>
70
- </td>
71
- </tr>
72
- </table>
73
- <!-- banner header -->
74
-
75
- <div id="bodyContent">
76
- <div id="content">
77
-
78
-
79
-
80
-
81
-
82
-
83
-
84
-
85
- <div class="sectiontitle">Constants</div>
86
- <table border='0' cellpadding='5'>
87
- <tr valign='top'>
88
- <td class="attr-name">INT_PROPERTIES</td>
89
- <td>=</td>
90
- <td class="attr-value">[:pid, :sessions]</td>
91
- </tr>
92
- </table>
93
-
94
- <div class="sectiontitle">Attributes</div>
95
- <table border='0' cellpadding='5'>
96
- <tr valign='top'>
97
- <td class='attr-rw'>
98
- [RW]
99
- </td>
100
- <td class='attr-name'>pid</td>
101
- <td class='attr-desc'></td>
102
- </tr>
103
- <tr valign='top'>
104
- <td class='attr-rw'>
105
- [RW]
106
- </td>
107
- <td class='attr-name'>sessions</td>
108
- <td class='attr-desc'></td>
109
- </tr>
110
- <tr valign='top'>
111
- <td class='attr-rw'>
112
- [RW]
113
- </td>
114
- <td class='attr-name'>socket_name</td>
115
- <td class='attr-desc'></td>
116
- </tr>
117
- <tr valign='top'>
118
- <td class='attr-rw'>
119
- [RW]
120
- </td>
121
- <td class='attr-name'>socket_type</td>
122
- <td class='attr-desc'></td>
123
- </tr>
124
- <tr valign='top'>
125
- <td class='attr-rw'>
126
- [RW]
127
- </td>
128
- <td class='attr-name'>uptime</td>
129
- <td class='attr-desc'></td>
130
- </tr>
131
- </table>
132
-
133
- </div>
134
-
135
- </div>
136
-
137
- </body>
138
- </html>