passenger 2.2.9 → 2.2.10

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 (435) hide show
  1. data/NEWS +10 -0
  2. data/doc/Architectural overview.html +202 -65
  3. data/doc/Security of user switching support.html +200 -63
  4. data/doc/Users guide Apache.html +266 -129
  5. data/doc/Users guide Nginx.html +234 -97
  6. data/doc/cxxapi/AbstractSpawnManager_8h-source.html +138 -0
  7. data/doc/cxxapi/Account_8h-source.html +202 -0
  8. data/doc/cxxapi/AccountsDatabase_8h-source.html +158 -0
  9. data/doc/cxxapi/AgentsStarter_8h-source.html +79 -0
  10. data/doc/cxxapi/BCrypt_8h-source.html +101 -0
  11. data/doc/cxxapi/BacktracesServer_8h-source.html +87 -0
  12. data/doc/cxxapi/Base64_8h-source.html +85 -0
  13. data/doc/cxxapi/Blowfish_8h-source.html +131 -0
  14. data/doc/cxxapi/Bucket_8h-source.html +1 -1
  15. data/doc/cxxapi/CachedFileStat_8h-source.html +49 -157
  16. data/doc/cxxapi/Configuration_8h-source.html +1 -1
  17. data/doc/cxxapi/Constants_8h-source.html +71 -0
  18. data/doc/cxxapi/ContentHandler_8h-source.html +92 -0
  19. data/doc/cxxapi/DirectoryMapper_8h-source.html +1 -1
  20. data/doc/cxxapi/Exceptions_8h-source.html +332 -236
  21. data/doc/cxxapi/FileChangeChecker_8h-source.html +237 -0
  22. data/doc/cxxapi/FileDescriptor_8h-source.html +206 -0
  23. data/doc/cxxapi/Hooks_8h-source.html +1 -1
  24. data/doc/cxxapi/HttpStatusExtractor_8h-source.html +378 -0
  25. data/doc/cxxapi/LoggingServer_8h-source.html +165 -0
  26. data/doc/cxxapi/Logging_8h-source.html +580 -112
  27. data/doc/cxxapi/MessageChannel_8h-source.html +789 -599
  28. data/doc/cxxapi/MessageClient_8h-source.html +297 -0
  29. data/doc/cxxapi/MessageServer_8h-source.html +607 -0
  30. data/doc/cxxapi/PoolOptions_8h-source.html +471 -278
  31. data/doc/cxxapi/Process_8h-source.html +272 -0
  32. data/doc/cxxapi/RandomGenerator_8h-source.html +156 -0
  33. data/doc/cxxapi/ResourceLocator_8h-source.html +104 -0
  34. data/doc/cxxapi/ScgiRequestParser_8h-source.html +399 -0
  35. data/doc/cxxapi/ServerInstanceDir_8h-source.html +356 -0
  36. data/doc/cxxapi/Session_8h-source.html +483 -0
  37. data/doc/cxxapi/SpawnManager_8h-source.html +590 -546
  38. data/doc/cxxapi/StaticContentHandler_8h-source.html +65 -0
  39. data/doc/cxxapi/StaticString_8h-source.html +214 -0
  40. data/doc/cxxapi/StringListCreator_8h-source.html +111 -0
  41. data/doc/cxxapi/SystemTime_8h-source.html +191 -78
  42. data/doc/cxxapi/Timer_8h-source.html +157 -0
  43. data/doc/cxxapi/Utils_8h-source.html +621 -434
  44. data/doc/cxxapi/Version_8h-source.html +59 -0
  45. data/doc/cxxapi/annotated.html +1 -1
  46. data/doc/cxxapi/apache2_2Configuration_8h-source.html +79 -0
  47. data/doc/cxxapi/classAgentWatcher-members.html +50 -0
  48. data/doc/cxxapi/classAgentWatcher.html +445 -0
  49. data/doc/cxxapi/classClient-members.html +4 -3
  50. data/doc/cxxapi/classClient.html +50 -46
  51. data/doc/cxxapi/classHooks-members.html +1 -1
  52. data/doc/cxxapi/classHooks.html +1 -1
  53. data/doc/cxxapi/classPassenger_1_1AbstractSpawnManager-members.html +37 -0
  54. data/doc/cxxapi/classPassenger_1_1AbstractSpawnManager.html +191 -0
  55. data/doc/cxxapi/classPassenger_1_1AbstractSpawnManager__inherit__graph.map +1 -0
  56. data/doc/cxxapi/classPassenger_1_1AbstractSpawnManager__inherit__graph.md5 +1 -0
  57. data/doc/cxxapi/classPassenger_1_1AbstractSpawnManager__inherit__graph.png +0 -0
  58. data/doc/cxxapi/{classPassenger_1_1DummySpawnManager-members.html → classPassenger_1_1ArgumentException-members.html} +3 -2
  59. data/doc/cxxapi/classPassenger_1_1ArgumentException.html +52 -0
  60. data/doc/cxxapi/classPassenger_1_1BacktracesServer-members.html +36 -0
  61. data/doc/cxxapi/classPassenger_1_1BacktracesServer.html +107 -0
  62. data/doc/cxxapi/classPassenger_1_1BacktracesServer__inherit__graph.map +1 -0
  63. data/doc/cxxapi/classPassenger_1_1BacktracesServer__inherit__graph.md5 +1 -0
  64. data/doc/cxxapi/classPassenger_1_1BacktracesServer__inherit__graph.png +0 -0
  65. data/doc/cxxapi/classPassenger_1_1BufferedUpload-members.html +3 -3
  66. data/doc/cxxapi/classPassenger_1_1BufferedUpload.html +18 -34
  67. data/doc/cxxapi/classPassenger_1_1BusyException-members.html +2 -1
  68. data/doc/cxxapi/classPassenger_1_1BusyException.html +3 -2
  69. data/doc/cxxapi/classPassenger_1_1ConfigurationException-members.html +2 -1
  70. data/doc/cxxapi/classPassenger_1_1ConfigurationException.html +3 -2
  71. data/doc/cxxapi/classPassenger_1_1DirectoryMapper-members.html +1 -1
  72. data/doc/cxxapi/classPassenger_1_1DirectoryMapper.html +1 -1
  73. data/doc/cxxapi/{classPassenger_1_1FileChecker-members.html → classPassenger_1_1EOFException-members.html} +3 -4
  74. data/doc/cxxapi/classPassenger_1_1EOFException.html +57 -0
  75. data/doc/cxxapi/classPassenger_1_1EOFException__inherit__graph.map +1 -0
  76. data/doc/cxxapi/classPassenger_1_1EOFException__inherit__graph.md5 +1 -0
  77. data/doc/cxxapi/classPassenger_1_1EOFException__inherit__graph.png +0 -0
  78. data/doc/cxxapi/classPassenger_1_1EventFd-members.html +33 -0
  79. data/doc/cxxapi/classPassenger_1_1EventFd.html +49 -0
  80. data/doc/cxxapi/classPassenger_1_1FileChangeChecker-members.html +37 -0
  81. data/doc/cxxapi/classPassenger_1_1FileChangeChecker.html +166 -0
  82. data/doc/cxxapi/classPassenger_1_1FileDescriptor-members.html +37 -0
  83. data/doc/cxxapi/classPassenger_1_1FileDescriptor.html +159 -0
  84. data/doc/cxxapi/classPassenger_1_1FileNotFoundException-members.html +2 -1
  85. data/doc/cxxapi/classPassenger_1_1FileNotFoundException.html +3 -2
  86. data/doc/cxxapi/classPassenger_1_1FileSystemException-members.html +2 -1
  87. data/doc/cxxapi/classPassenger_1_1FileSystemException.html +3 -2
  88. data/doc/cxxapi/{classPassenger_1_1ApplicationPoolServer-members.html → classPassenger_1_1HttpStatusExtractor-members.html} +6 -5
  89. data/doc/cxxapi/classPassenger_1_1HttpStatusExtractor.html +128 -0
  90. data/doc/cxxapi/classPassenger_1_1IOException-members.html +2 -1
  91. data/doc/cxxapi/classPassenger_1_1IOException.html +4 -3
  92. data/doc/cxxapi/classPassenger_1_1IOException__inherit__graph.map +2 -1
  93. data/doc/cxxapi/classPassenger_1_1IOException__inherit__graph.md5 +1 -1
  94. data/doc/cxxapi/classPassenger_1_1IOException__inherit__graph.png +0 -0
  95. data/doc/cxxapi/classPassenger_1_1MemZeroGuard-members.html +36 -0
  96. data/doc/cxxapi/classPassenger_1_1MemZeroGuard.html +147 -0
  97. data/doc/cxxapi/classPassenger_1_1MessageChannel-members.html +12 -5
  98. data/doc/cxxapi/classPassenger_1_1MessageChannel.html +267 -34
  99. data/doc/cxxapi/classPassenger_1_1MessageServer-members.html +46 -0
  100. data/doc/cxxapi/classPassenger_1_1MessageServer.html +438 -0
  101. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1ClientContext-members.html +33 -0
  102. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1ClientContext.html +56 -0
  103. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1ClientContext__inherit__graph.map +1 -0
  104. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1ClientContext__inherit__graph.md5 +1 -0
  105. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1ClientContext__inherit__graph.png +0 -0
  106. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1CommonClientContext-members.html +38 -0
  107. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1CommonClientContext.html +175 -0
  108. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1CommonClientContext__inherit__graph.map +1 -0
  109. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1CommonClientContext__inherit__graph.md5 +1 -0
  110. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1CommonClientContext__inherit__graph.png +0 -0
  111. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1Handler-members.html +36 -0
  112. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1Handler.html +176 -0
  113. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1Handler__inherit__graph.map +1 -0
  114. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1Handler__inherit__graph.md5 +1 -0
  115. data/doc/cxxapi/classPassenger_1_1MessageServer_1_1Handler__inherit__graph.png +0 -0
  116. data/doc/cxxapi/classPassenger_1_1Process-members.html +40 -0
  117. data/doc/cxxapi/classPassenger_1_1Process.html +266 -0
  118. data/doc/cxxapi/classPassenger_1_1RandomGenerator-members.html +33 -0
  119. data/doc/cxxapi/classPassenger_1_1RandomGenerator.html +51 -0
  120. data/doc/cxxapi/classPassenger_1_1RuntimeException-members.html +2 -1
  121. data/doc/cxxapi/classPassenger_1_1RuntimeException.html +3 -2
  122. data/doc/cxxapi/classPassenger_1_1ScgiRequestParser-members.html +47 -0
  123. data/doc/cxxapi/classPassenger_1_1ScgiRequestParser.html +302 -0
  124. data/doc/cxxapi/classPassenger_1_1SecurityException-members.html +33 -0
  125. data/doc/cxxapi/classPassenger_1_1SecurityException.html +52 -0
  126. data/doc/cxxapi/classPassenger_1_1Session-members.html +50 -0
  127. data/doc/cxxapi/classPassenger_1_1Session.html +577 -0
  128. data/doc/cxxapi/classPassenger_1_1Session__inherit__graph.map +1 -0
  129. data/doc/cxxapi/classPassenger_1_1Session__inherit__graph.md5 +1 -0
  130. data/doc/cxxapi/classPassenger_1_1Session__inherit__graph.png +0 -0
  131. data/doc/cxxapi/classPassenger_1_1SpawnException-members.html +2 -1
  132. data/doc/cxxapi/classPassenger_1_1SpawnException.html +5 -4
  133. data/doc/cxxapi/classPassenger_1_1SpawnManager-members.html +8 -5
  134. data/doc/cxxapi/classPassenger_1_1SpawnManager.html +127 -45
  135. data/doc/cxxapi/classPassenger_1_1SpawnManager__inherit__graph.map +1 -0
  136. data/doc/cxxapi/classPassenger_1_1SpawnManager__inherit__graph.md5 +1 -0
  137. data/doc/cxxapi/classPassenger_1_1SpawnManager__inherit__graph.png +0 -0
  138. data/doc/cxxapi/classPassenger_1_1StandardSession-members.html +51 -0
  139. data/doc/cxxapi/classPassenger_1_1StandardSession.html +415 -0
  140. data/doc/cxxapi/classPassenger_1_1StandardSession__inherit__graph.map +1 -0
  141. data/doc/cxxapi/classPassenger_1_1StandardSession__inherit__graph.md5 +1 -0
  142. data/doc/cxxapi/classPassenger_1_1StandardSession__inherit__graph.png +0 -0
  143. data/doc/cxxapi/classPassenger_1_1StaticString-members.html +33 -0
  144. data/doc/cxxapi/classPassenger_1_1StaticString.html +54 -0
  145. data/doc/cxxapi/classPassenger_1_1SystemException-members.html +2 -1
  146. data/doc/cxxapi/classPassenger_1_1SystemException.html +4 -3
  147. data/doc/cxxapi/classPassenger_1_1SystemException__inherit__graph.map +1 -0
  148. data/doc/cxxapi/classPassenger_1_1SystemException__inherit__graph.md5 +1 -1
  149. data/doc/cxxapi/classPassenger_1_1SystemException__inherit__graph.png +0 -0
  150. data/doc/cxxapi/classPassenger_1_1SystemTime-members.html +9 -1
  151. data/doc/cxxapi/classPassenger_1_1SystemTime.html +92 -8
  152. data/doc/cxxapi/classPassenger_1_1TimeRetrievalException-members.html +37 -0
  153. data/doc/cxxapi/classPassenger_1_1TimeRetrievalException.html +57 -0
  154. data/doc/cxxapi/classPassenger_1_1TimeRetrievalException__inherit__graph.map +1 -0
  155. data/doc/cxxapi/classPassenger_1_1TimeRetrievalException__inherit__graph.md5 +1 -0
  156. data/doc/cxxapi/classPassenger_1_1TimeRetrievalException__inherit__graph.png +0 -0
  157. data/doc/cxxapi/classPassenger_1_1TimeoutException-members.html +33 -0
  158. data/doc/cxxapi/classPassenger_1_1TimeoutException.html +50 -0
  159. data/doc/cxxapi/{classPassenger_1_1Application-members.html → classPassenger_1_1Timer-members.html} +8 -7
  160. data/doc/cxxapi/classPassenger_1_1Timer.html +163 -0
  161. data/doc/cxxapi/classServer-members.html +33 -0
  162. data/doc/cxxapi/classServer.html +46 -0
  163. data/doc/cxxapi/classServerInstanceDirToucher-members.html +33 -0
  164. data/doc/cxxapi/classServerInstanceDirToucher.html +43 -0
  165. data/doc/cxxapi/classes.html +1 -1
  166. data/doc/cxxapi/definitions_8h-source.html +1 -1
  167. data/doc/cxxapi/files.html +1 -1
  168. data/doc/cxxapi/functions.html +1 -1
  169. data/doc/cxxapi/{functions_type.html → functions_enum.html} +7 -5
  170. data/doc/cxxapi/functions_eval.html +55 -0
  171. data/doc/cxxapi/functions_func.html +1 -1
  172. data/doc/cxxapi/functions_vars.html +106 -9
  173. data/doc/cxxapi/graph_legend.html +1 -1
  174. data/doc/cxxapi/group__Configuration.html +1 -1
  175. data/doc/cxxapi/group__Core.html +1 -1
  176. data/doc/cxxapi/group__Exceptions.html +17 -1
  177. data/doc/cxxapi/group__Hooks.html +1 -1
  178. data/doc/cxxapi/group__Support.html +1 -1
  179. data/doc/cxxapi/hierarchy.html +34 -12
  180. data/doc/cxxapi/inherit__graph__0.map +1 -1
  181. data/doc/cxxapi/inherit__graph__0.md5 +1 -1
  182. data/doc/cxxapi/inherit__graph__0.png +0 -0
  183. data/doc/cxxapi/inherit__graph__1.map +1 -1
  184. data/doc/cxxapi/inherit__graph__1.md5 +1 -1
  185. data/doc/cxxapi/inherit__graph__1.png +0 -0
  186. data/doc/cxxapi/inherit__graph__10.map +1 -1
  187. data/doc/cxxapi/inherit__graph__10.md5 +1 -1
  188. data/doc/cxxapi/inherit__graph__10.png +0 -0
  189. data/doc/cxxapi/inherit__graph__11.map +1 -1
  190. data/doc/cxxapi/inherit__graph__11.md5 +1 -1
  191. data/doc/cxxapi/inherit__graph__11.png +0 -0
  192. data/doc/cxxapi/inherit__graph__12.map +1 -1
  193. data/doc/cxxapi/inherit__graph__12.md5 +1 -1
  194. data/doc/cxxapi/inherit__graph__12.png +0 -0
  195. data/doc/cxxapi/inherit__graph__13.map +1 -1
  196. data/doc/cxxapi/inherit__graph__13.md5 +1 -1
  197. data/doc/cxxapi/inherit__graph__13.png +0 -0
  198. data/doc/cxxapi/inherit__graph__14.map +3 -2
  199. data/doc/cxxapi/inherit__graph__14.md5 +1 -1
  200. data/doc/cxxapi/inherit__graph__14.png +0 -0
  201. data/doc/cxxapi/inherit__graph__15.map +1 -1
  202. data/doc/cxxapi/inherit__graph__15.md5 +1 -1
  203. data/doc/cxxapi/inherit__graph__15.png +0 -0
  204. data/doc/cxxapi/inherit__graph__16.map +1 -1
  205. data/doc/cxxapi/inherit__graph__16.md5 +1 -1
  206. data/doc/cxxapi/inherit__graph__16.png +0 -0
  207. data/doc/cxxapi/inherit__graph__17.map +1 -1
  208. data/doc/cxxapi/inherit__graph__17.md5 +1 -1
  209. data/doc/cxxapi/inherit__graph__17.png +0 -0
  210. data/doc/cxxapi/inherit__graph__18.map +2 -1
  211. data/doc/cxxapi/inherit__graph__18.md5 +1 -1
  212. data/doc/cxxapi/inherit__graph__18.png +0 -0
  213. data/doc/cxxapi/inherit__graph__19.map +1 -1
  214. data/doc/cxxapi/inherit__graph__19.md5 +1 -1
  215. data/doc/cxxapi/inherit__graph__19.png +0 -0
  216. data/doc/cxxapi/inherit__graph__2.map +1 -1
  217. data/doc/cxxapi/inherit__graph__2.md5 +1 -1
  218. data/doc/cxxapi/inherit__graph__2.png +0 -0
  219. data/doc/cxxapi/inherit__graph__20.map +1 -2
  220. data/doc/cxxapi/inherit__graph__20.md5 +1 -1
  221. data/doc/cxxapi/inherit__graph__20.png +0 -0
  222. data/doc/cxxapi/inherit__graph__21.map +1 -1
  223. data/doc/cxxapi/inherit__graph__21.md5 +1 -1
  224. data/doc/cxxapi/inherit__graph__21.png +0 -0
  225. data/doc/cxxapi/inherit__graph__22.map +1 -0
  226. data/doc/cxxapi/inherit__graph__22.md5 +1 -0
  227. data/doc/cxxapi/inherit__graph__22.png +0 -0
  228. data/doc/cxxapi/inherit__graph__23.map +1 -0
  229. data/doc/cxxapi/inherit__graph__23.md5 +1 -0
  230. data/doc/cxxapi/inherit__graph__23.png +0 -0
  231. data/doc/cxxapi/inherit__graph__24.map +1 -0
  232. data/doc/cxxapi/inherit__graph__24.md5 +1 -0
  233. data/doc/cxxapi/inherit__graph__24.png +0 -0
  234. data/doc/cxxapi/inherit__graph__25.map +1 -0
  235. data/doc/cxxapi/inherit__graph__25.md5 +1 -0
  236. data/doc/cxxapi/inherit__graph__25.png +0 -0
  237. data/doc/cxxapi/inherit__graph__26.map +1 -0
  238. data/doc/cxxapi/inherit__graph__26.md5 +1 -0
  239. data/doc/cxxapi/inherit__graph__26.png +0 -0
  240. data/doc/cxxapi/inherit__graph__27.map +2 -0
  241. data/doc/cxxapi/inherit__graph__27.md5 +1 -0
  242. data/doc/cxxapi/inherit__graph__27.png +0 -0
  243. data/doc/cxxapi/inherit__graph__28.map +1 -0
  244. data/doc/cxxapi/inherit__graph__28.md5 +1 -0
  245. data/doc/cxxapi/inherit__graph__28.png +0 -0
  246. data/doc/cxxapi/inherit__graph__29.map +1 -0
  247. data/doc/cxxapi/inherit__graph__29.md5 +1 -0
  248. data/doc/cxxapi/inherit__graph__29.png +0 -0
  249. data/doc/cxxapi/inherit__graph__3.map +2 -1
  250. data/doc/cxxapi/inherit__graph__3.md5 +1 -1
  251. data/doc/cxxapi/inherit__graph__3.png +0 -0
  252. data/doc/cxxapi/inherit__graph__30.map +1 -0
  253. data/doc/cxxapi/inherit__graph__30.md5 +1 -0
  254. data/doc/cxxapi/inherit__graph__30.png +0 -0
  255. data/doc/cxxapi/inherit__graph__31.map +3 -0
  256. data/doc/cxxapi/inherit__graph__31.md5 +1 -0
  257. data/doc/cxxapi/inherit__graph__31.png +0 -0
  258. data/doc/cxxapi/inherit__graph__32.map +1 -0
  259. data/doc/cxxapi/inherit__graph__32.md5 +1 -0
  260. data/doc/cxxapi/inherit__graph__32.png +0 -0
  261. data/doc/cxxapi/inherit__graph__33.map +1 -0
  262. data/doc/cxxapi/inherit__graph__33.md5 +1 -0
  263. data/doc/cxxapi/inherit__graph__33.png +0 -0
  264. data/doc/cxxapi/inherit__graph__34.map +1 -0
  265. data/doc/cxxapi/inherit__graph__34.md5 +1 -0
  266. data/doc/cxxapi/inherit__graph__34.png +0 -0
  267. data/doc/cxxapi/inherit__graph__35.map +1 -0
  268. data/doc/cxxapi/inherit__graph__35.md5 +1 -0
  269. data/doc/cxxapi/inherit__graph__35.png +0 -0
  270. data/doc/cxxapi/inherit__graph__36.map +1 -0
  271. data/doc/cxxapi/inherit__graph__36.md5 +1 -0
  272. data/doc/cxxapi/inherit__graph__36.png +0 -0
  273. data/doc/cxxapi/inherit__graph__4.map +1 -1
  274. data/doc/cxxapi/inherit__graph__4.md5 +1 -1
  275. data/doc/cxxapi/inherit__graph__4.png +0 -0
  276. data/doc/cxxapi/inherit__graph__5.map +1 -1
  277. data/doc/cxxapi/inherit__graph__5.md5 +1 -1
  278. data/doc/cxxapi/inherit__graph__5.png +0 -0
  279. data/doc/cxxapi/inherit__graph__6.map +1 -2
  280. data/doc/cxxapi/inherit__graph__6.md5 +1 -1
  281. data/doc/cxxapi/inherit__graph__6.png +0 -0
  282. data/doc/cxxapi/inherit__graph__7.map +1 -1
  283. data/doc/cxxapi/inherit__graph__7.md5 +1 -1
  284. data/doc/cxxapi/inherit__graph__7.png +0 -0
  285. data/doc/cxxapi/inherit__graph__8.map +1 -1
  286. data/doc/cxxapi/inherit__graph__8.md5 +1 -1
  287. data/doc/cxxapi/inherit__graph__8.png +0 -0
  288. data/doc/cxxapi/inherit__graph__9.map +1 -1
  289. data/doc/cxxapi/inherit__graph__9.md5 +1 -1
  290. data/doc/cxxapi/inherit__graph__9.png +0 -0
  291. data/doc/cxxapi/inherits.html +81 -41
  292. data/doc/cxxapi/main.html +1 -1
  293. data/doc/cxxapi/md5_8h-source.html +121 -0
  294. data/doc/cxxapi/modules.html +1 -1
  295. data/doc/cxxapi/namespacePassenger.html +651 -0
  296. data/doc/cxxapi/namespacemembers.html +155 -0
  297. data/doc/cxxapi/namespacemembers_enum.html +46 -0
  298. data/doc/cxxapi/namespacemembers_eval.html +52 -0
  299. data/doc/cxxapi/namespacemembers_func.html +139 -0
  300. data/doc/cxxapi/namespacemembers_type.html +50 -0
  301. data/doc/cxxapi/namespaces.html +34 -0
  302. data/doc/cxxapi/nginx_2Configuration_8h-source.html +114 -0
  303. data/doc/cxxapi/ngx__http__passenger__module_8h-source.html +91 -0
  304. data/doc/cxxapi/structPassenger_1_1AnythingToString-members.html +2 -1
  305. data/doc/cxxapi/structPassenger_1_1AnythingToString.html +3 -2
  306. data/doc/cxxapi/structPassenger_1_1AnythingToString_3_01vector_3_01string_01_4_01_4-members.html +2 -1
  307. data/doc/cxxapi/structPassenger_1_1AnythingToString_3_01vector_3_01string_01_4_01_4.html +3 -2
  308. data/doc/cxxapi/structPassenger_1_1MessageServer_1_1DisconnectEventBroadcastGuard-members.html +33 -0
  309. data/doc/cxxapi/structPassenger_1_1MessageServer_1_1DisconnectEventBroadcastGuard.html +49 -0
  310. data/doc/cxxapi/structPassenger_1_1PoolOptions-members.html +19 -7
  311. data/doc/cxxapi/structPassenger_1_1PoolOptions.html +323 -53
  312. data/doc/cxxapi/structPassenger_1_1StaticString_1_1Hash-members.html +33 -0
  313. data/doc/cxxapi/structPassenger_1_1StaticString_1_1Hash.html +49 -0
  314. data/ext/common/MessageChannel.h +48 -4
  315. data/ext/common/Version.h +1 -1
  316. data/ext/nginx/HttpStatusExtractor.h +1 -0
  317. data/ext/nginx/ScgiRequestParser.h +1 -0
  318. data/ext/phusion_passenger/native_support.c +5 -1
  319. data/lib/phusion_passenger/constants.rb +1 -1
  320. data/lib/phusion_passenger/message_channel.rb +45 -3
  321. data/lib/phusion_passenger/rack/application_spawner.rb +4 -0
  322. data/lib/phusion_passenger/railz/application_spawner.rb +19 -1
  323. data/lib/phusion_passenger/utils.rb +3 -3
  324. data/lib/phusion_passenger/utils/rewindable_input.rb +5 -0
  325. data/test/MessageChannelTest.cpp +9 -1
  326. data/test/stub/message_channel.rb +1 -1
  327. data/test/stub/message_channel_2.rb +1 -1
  328. data/test/stub/message_channel_3.rb +2 -2
  329. metadata +173 -113
  330. data/doc/cxxapi/ApplicationPoolServer_8h-source.html +0 -833
  331. data/doc/cxxapi/ApplicationPool_8h-source.html +0 -226
  332. data/doc/cxxapi/Application_8h-source.html +0 -553
  333. data/doc/cxxapi/DummySpawnManager_8h-source.html +0 -130
  334. data/doc/cxxapi/FileChecker_8h-source.html +0 -134
  335. data/doc/cxxapi/StandardApplicationPool_8h-source.html +0 -842
  336. data/doc/cxxapi/classPassenger_1_1Application.html +0 -231
  337. data/doc/cxxapi/classPassenger_1_1ApplicationPool-members.html +0 -41
  338. data/doc/cxxapi/classPassenger_1_1ApplicationPool.html +0 -323
  339. data/doc/cxxapi/classPassenger_1_1ApplicationPoolServer.html +0 -227
  340. data/doc/cxxapi/classPassenger_1_1ApplicationPool__inherit__graph.map +0 -1
  341. data/doc/cxxapi/classPassenger_1_1ApplicationPool__inherit__graph.md5 +0 -1
  342. data/doc/cxxapi/classPassenger_1_1ApplicationPool__inherit__graph.png +0 -0
  343. data/doc/cxxapi/classPassenger_1_1Application_1_1Session-members.html +0 -44
  344. data/doc/cxxapi/classPassenger_1_1Application_1_1Session.html +0 -403
  345. data/doc/cxxapi/classPassenger_1_1DummySpawnManager.html +0 -53
  346. data/doc/cxxapi/classPassenger_1_1FileChecker.html +0 -124
  347. data/doc/cxxapi/classPassenger_1_1StandardApplicationPool-members.html +0 -44
  348. data/doc/cxxapi/classPassenger_1_1StandardApplicationPool.html +0 -342
  349. data/doc/cxxapi/classPassenger_1_1StandardApplicationPool__inherit__graph.map +0 -1
  350. data/doc/cxxapi/classPassenger_1_1StandardApplicationPool__inherit__graph.md5 +0 -1
  351. data/doc/cxxapi/classPassenger_1_1StandardApplicationPool__inherit__graph.png +0 -0
  352. data/doc/rdoc/classes/ConditionVariable.html +0 -194
  353. data/doc/rdoc/classes/Exception.html +0 -120
  354. data/doc/rdoc/classes/GC.html +0 -113
  355. data/doc/rdoc/classes/IO.html +0 -169
  356. data/doc/rdoc/classes/PhusionPassenger.html +0 -239
  357. data/doc/rdoc/classes/PhusionPassenger/AbstractInstaller.html +0 -153
  358. data/doc/rdoc/classes/PhusionPassenger/AbstractRequestHandler.html +0 -517
  359. data/doc/rdoc/classes/PhusionPassenger/AbstractServer.html +0 -719
  360. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/ServerAlreadyStarted.html +0 -97
  361. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/ServerError.html +0 -96
  362. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/ServerNotStarted.html +0 -97
  363. data/doc/rdoc/classes/PhusionPassenger/AbstractServer/UnknownMessage.html +0 -96
  364. data/doc/rdoc/classes/PhusionPassenger/AbstractServerCollection.html +0 -598
  365. data/doc/rdoc/classes/PhusionPassenger/AdminTools.html +0 -140
  366. data/doc/rdoc/classes/PhusionPassenger/AdminTools/ControlProcess.html +0 -317
  367. data/doc/rdoc/classes/PhusionPassenger/AdminTools/ControlProcess/Instance.html +0 -138
  368. data/doc/rdoc/classes/PhusionPassenger/AppInitError.html +0 -154
  369. data/doc/rdoc/classes/PhusionPassenger/Application.html +0 -283
  370. data/doc/rdoc/classes/PhusionPassenger/ConsoleTextTemplate.html +0 -172
  371. data/doc/rdoc/classes/PhusionPassenger/FrameworkInitError.html +0 -145
  372. data/doc/rdoc/classes/PhusionPassenger/HTMLTemplate.html +0 -175
  373. data/doc/rdoc/classes/PhusionPassenger/InitializationError.html +0 -141
  374. data/doc/rdoc/classes/PhusionPassenger/InvalidPath.html +0 -92
  375. data/doc/rdoc/classes/PhusionPassenger/MessageChannel.html +0 -489
  376. data/doc/rdoc/classes/PhusionPassenger/NativeSupport.html +0 -350
  377. data/doc/rdoc/classes/PhusionPassenger/Rack.html +0 -91
  378. data/doc/rdoc/classes/PhusionPassenger/Rack/ApplicationSpawner.html +0 -188
  379. data/doc/rdoc/classes/PhusionPassenger/Rack/RequestHandler.html +0 -199
  380. data/doc/rdoc/classes/PhusionPassenger/Railz.html +0 -95
  381. data/doc/rdoc/classes/PhusionPassenger/Railz/ApplicationSpawner.html +0 -438
  382. data/doc/rdoc/classes/PhusionPassenger/Railz/ApplicationSpawner/Error.html +0 -98
  383. data/doc/rdoc/classes/PhusionPassenger/Railz/CGIFixed.html +0 -200
  384. data/doc/rdoc/classes/PhusionPassenger/Railz/FrameworkSpawner.html +0 -436
  385. data/doc/rdoc/classes/PhusionPassenger/Railz/FrameworkSpawner/Error.html +0 -98
  386. data/doc/rdoc/classes/PhusionPassenger/Railz/RequestHandler.html +0 -155
  387. data/doc/rdoc/classes/PhusionPassenger/SpawnManager.html +0 -402
  388. data/doc/rdoc/classes/PhusionPassenger/UnknownError.html +0 -125
  389. data/doc/rdoc/classes/PhusionPassenger/Utils.html +0 -805
  390. data/doc/rdoc/classes/PhusionPassenger/Utils/PseudoIO.html +0 -169
  391. data/doc/rdoc/classes/PhusionPassenger/Utils/RewindableInput.html +0 -247
  392. data/doc/rdoc/classes/PhusionPassenger/Utils/RewindableInput/Tempfile.html +0 -120
  393. data/doc/rdoc/classes/PhusionPassenger/VersionNotFound.html +0 -140
  394. data/doc/rdoc/classes/PhusionPassenger/WSGI.html +0 -89
  395. data/doc/rdoc/classes/PhusionPassenger/WSGI/ApplicationSpawner.html +0 -188
  396. data/doc/rdoc/classes/PlatformInfo.html +0 -866
  397. data/doc/rdoc/classes/RakeExtensions.html +0 -197
  398. data/doc/rdoc/classes/Signal.html +0 -139
  399. data/doc/rdoc/created.rid +0 -1
  400. data/doc/rdoc/files/DEVELOPERS_TXT.html +0 -255
  401. data/doc/rdoc/files/README.html +0 -157
  402. data/doc/rdoc/files/ext/phusion_passenger/native_support_c.html +0 -92
  403. data/doc/rdoc/files/lib/phusion_passenger/abstract_installer_rb.html +0 -129
  404. data/doc/rdoc/files/lib/phusion_passenger/abstract_request_handler_rb.html +0 -129
  405. data/doc/rdoc/files/lib/phusion_passenger/abstract_server_collection_rb.html +0 -126
  406. data/doc/rdoc/files/lib/phusion_passenger/abstract_server_rb.html +0 -128
  407. data/doc/rdoc/files/lib/phusion_passenger/admin_tools/control_process_rb.html +0 -130
  408. data/doc/rdoc/files/lib/phusion_passenger/admin_tools_rb.html +0 -122
  409. data/doc/rdoc/files/lib/phusion_passenger/application_rb.html +0 -127
  410. data/doc/rdoc/files/lib/phusion_passenger/console_text_template_rb.html +0 -126
  411. data/doc/rdoc/files/lib/phusion_passenger/constants_rb.html +0 -122
  412. data/doc/rdoc/files/lib/phusion_passenger/dependencies_rb.html +0 -134
  413. data/doc/rdoc/files/lib/phusion_passenger/events_rb.html +0 -122
  414. data/doc/rdoc/files/lib/phusion_passenger/exceptions_rb.html +0 -122
  415. data/doc/rdoc/files/lib/phusion_passenger/html_template_rb.html +0 -126
  416. data/doc/rdoc/files/lib/phusion_passenger/message_channel_rb.html +0 -120
  417. data/doc/rdoc/files/lib/phusion_passenger/packaging_rb.html +0 -122
  418. data/doc/rdoc/files/lib/phusion_passenger/platform_info_rb.html +0 -127
  419. data/doc/rdoc/files/lib/phusion_passenger/rack/application_spawner_rb.html +0 -133
  420. data/doc/rdoc/files/lib/phusion_passenger/rack/request_handler_rb.html +0 -125
  421. data/doc/rdoc/files/lib/phusion_passenger/railz/application_spawner_rb.html +0 -140
  422. data/doc/rdoc/files/lib/phusion_passenger/railz/cgi_fixed_rb.html +0 -126
  423. data/doc/rdoc/files/lib/phusion_passenger/railz/framework_spawner_rb.html +0 -145
  424. data/doc/rdoc/files/lib/phusion_passenger/railz/request_handler_rb.html +0 -125
  425. data/doc/rdoc/files/lib/phusion_passenger/simple_benchmarking_rb.html +0 -122
  426. data/doc/rdoc/files/lib/phusion_passenger/spawn_manager_rb.html +0 -159
  427. data/doc/rdoc/files/lib/phusion_passenger/utils/rewindable_input_rb.html +0 -100
  428. data/doc/rdoc/files/lib/phusion_passenger/utils_rb.html +0 -174
  429. data/doc/rdoc/files/lib/phusion_passenger/wsgi/application_spawner_rb.html +0 -129
  430. data/doc/rdoc/files/misc/rake/extensions_rb.html +0 -130
  431. data/doc/rdoc/fr_class_index.html +0 -93
  432. data/doc/rdoc/fr_file_index.html +0 -77
  433. data/doc/rdoc/fr_method_index.html +0 -212
  434. data/doc/rdoc/index.html +0 -26
  435. data/doc/rdoc/rdoc-style.css +0 -187
@@ -3,7 +3,7 @@
3
3
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
4
4
  <head>
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
6
- <meta name="generator" content="AsciiDoc 8.4.2" />
6
+ <meta name="generator" content="AsciiDoc 8.5.2" />
7
7
  <title>Phusion Passenger users guide, Nginx version</title>
8
8
  <style type="text/css">
9
9
  /* Debug borders */
@@ -91,7 +91,7 @@ span#author {
91
91
  }
92
92
  span#email {
93
93
  }
94
- span#revision {
94
+ span#revnumber, span#revdate, span#revremark {
95
95
  font-family: sans-serif;
96
96
  }
97
97
 
@@ -118,12 +118,14 @@ div#preamble {
118
118
  div.tableblock, div.imageblock, div.exampleblock, div.verseblock,
119
119
  div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
120
120
  div.admonitionblock {
121
- margin-top: 1.5em;
121
+ margin-top: 1.0em;
122
122
  margin-bottom: 1.5em;
123
123
  }
124
124
  div.admonitionblock {
125
- margin-top: 2.5em;
126
- margin-bottom: 2.5em;
125
+ margin-top: 2.0em;
126
+ margin-bottom: 2.0em;
127
+ margin-right: 10%;
128
+ color: #606060;
127
129
  }
128
130
 
129
131
  div.content { /* Block element content. */
@@ -165,19 +167,19 @@ div.listingblock > div.content {
165
167
  padding: 0.5em;
166
168
  }
167
169
 
168
- div.quoteblock {
169
- padding-left: 2.0em;
170
+ div.quoteblock, div.verseblock {
171
+ padding-left: 1.0em;
172
+ margin-left: 1.0em;
170
173
  margin-right: 10%;
174
+ border-left: 5px solid #dddddd;
175
+ color: #777777;
171
176
  }
177
+
172
178
  div.quoteblock > div.attribution {
173
179
  padding-top: 0.5em;
174
180
  text-align: right;
175
181
  }
176
182
 
177
- div.verseblock {
178
- padding-left: 2.0em;
179
- margin-right: 10%;
180
- }
181
183
  div.verseblock > div.content {
182
184
  white-space: pre;
183
185
  }
@@ -200,17 +202,17 @@ div.admonitionblock .icon {
200
202
  }
201
203
  div.admonitionblock td.content {
202
204
  padding-left: 0.5em;
203
- border-left: 2px solid silver;
205
+ border-left: 3px solid #dddddd;
204
206
  }
205
207
 
206
208
  div.exampleblock > div.content {
207
- border-left: 2px solid silver;
208
- padding: 0.5em;
209
+ border-left: 3px solid #dddddd;
210
+ padding-left: 0.5em;
209
211
  }
210
212
 
211
213
  div.imageblock div.content { padding-left: 0; }
212
- div.imageblock img { border: 1px solid silver; }
213
214
  span.image img { border-style: none; }
215
+ a.image:visited { color: white; }
214
216
 
215
217
  dl {
216
218
  margin-top: 0.8em;
@@ -255,7 +257,7 @@ div.compact div, div.compact div {
255
257
  div.tableblock > table {
256
258
  border: 3px solid #527bbd;
257
259
  }
258
- thead {
260
+ thead, p.table.header {
259
261
  font-family: sans-serif;
260
262
  font-weight: bold;
261
263
  }
@@ -310,10 +312,42 @@ div.hdlist.compact tr {
310
312
  background: yellow;
311
313
  }
312
314
 
315
+ .footnote, .footnoteref {
316
+ font-size: 0.8em;
317
+ }
318
+
319
+ span.footnote, span.footnoteref {
320
+ vertical-align: super;
321
+ }
322
+
323
+ #footnotes {
324
+ margin: 20px 0 20px 0;
325
+ padding: 7px 0 0 0;
326
+ }
327
+
328
+ #footnotes div.footnote {
329
+ margin: 0 0 5px 0;
330
+ }
331
+
332
+ #footnotes hr {
333
+ border: none;
334
+ border-top: 1px solid silver;
335
+ height: 1px;
336
+ text-align: left;
337
+ margin-left: 0;
338
+ width: 20%;
339
+ min-width: 100px;
340
+ }
341
+
342
+
313
343
  @media print {
314
344
  div#footer-badges { display: none; }
315
345
  }
316
346
 
347
+ div#toc {
348
+ margin-bottom: 2.5em;
349
+ }
350
+
317
351
  div#toctitle {
318
352
  color: #527bbd;
319
353
  font-family: sans-serif;
@@ -339,10 +373,57 @@ div.toclevel4 {
339
373
  margin-left: 6em;
340
374
  font-size: 0.9em;
341
375
  }
376
+ /* Workarounds for IE6's broken and incomplete CSS2. */
377
+
378
+ div.sidebar-content {
379
+ background: #ffffee;
380
+ border: 1px solid silver;
381
+ padding: 0.5em;
382
+ }
383
+ div.sidebar-title, div.image-title {
384
+ color: #527bbd;
385
+ font-family: sans-serif;
386
+ font-weight: bold;
387
+ margin-top: 0.0em;
388
+ margin-bottom: 0.5em;
389
+ }
390
+
391
+ div.listingblock div.content {
392
+ border: 1px solid silver;
393
+ background: #f4f4f4;
394
+ padding: 0.5em;
395
+ }
396
+
397
+ div.quoteblock-attribution {
398
+ padding-top: 0.5em;
399
+ text-align: right;
400
+ }
401
+
402
+ div.verseblock-content {
403
+ white-space: pre;
404
+ }
405
+ div.verseblock-attribution {
406
+ padding-top: 0.75em;
407
+ text-align: left;
408
+ }
409
+
410
+ div.exampleblock-content {
411
+ border-left: 3px solid #dddddd;
412
+ padding-left: 0.5em;
413
+ }
414
+
415
+ /* IE6 sets dynamically generated links as visited. */
416
+ div#toc a:visited { color: blue; }
342
417
  </style>
343
418
  <script type="text/javascript">
344
419
  /*<![CDATA[*/
345
- window.onload = function(){generateToc(3)}
420
+ window.onload = function(){asciidoc.footnotes(); asciidoc.toc(3);}
421
+ var asciidoc = { // Namespace.
422
+
423
+ /////////////////////////////////////////////////////////////////////
424
+ // Table Of Contents generator
425
+ /////////////////////////////////////////////////////////////////////
426
+
346
427
  /* Author: Mihai Bazon, September 2002
347
428
  * http://students.infoiasi.ro/~mishoo
348
429
  *
@@ -354,53 +435,55 @@ window.onload = function(){generateToc(3)}
354
435
  */
355
436
 
356
437
  /* modified by Troy D. Hanson, September 2006. License: GPL */
357
- /* modified by Stuart Rackham, October 2006. License: GPL */
358
-
359
- function getText(el) {
360
- var text = "";
361
- for (var i = el.firstChild; i != null; i = i.nextSibling) {
362
- if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
363
- text += i.data;
364
- else if (i.firstChild != null)
365
- text += getText(i);
366
- }
367
- return text;
368
- }
438
+ /* modified by Stuart Rackham, 2006, 2009. License: GPL */
369
439
 
370
- function TocEntry(el, text, toclevel) {
371
- this.element = el;
372
- this.text = text;
373
- this.toclevel = toclevel;
374
- }
440
+ // toclevels = 1..4.
441
+ toc: function (toclevels) {
375
442
 
376
- function tocEntries(el, toclevels) {
377
- var result = new Array;
378
- var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
379
- // Function that scans the DOM tree for header elements (the DOM2
380
- // nodeIterator API would be a better technique but not supported by all
381
- // browsers).
382
- var iterate = function (el) {
443
+ function getText(el) {
444
+ var text = "";
383
445
  for (var i = el.firstChild; i != null; i = i.nextSibling) {
384
- if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
385
- var mo = re.exec(i.tagName)
386
- if (mo)
387
- result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
388
- iterate(i);
446
+ if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
447
+ text += i.data;
448
+ else if (i.firstChild != null)
449
+ text += getText(i);
450
+ }
451
+ return text;
452
+ }
453
+
454
+ function TocEntry(el, text, toclevel) {
455
+ this.element = el;
456
+ this.text = text;
457
+ this.toclevel = toclevel;
458
+ }
459
+
460
+ function tocEntries(el, toclevels) {
461
+ var result = new Array;
462
+ var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
463
+ // Function that scans the DOM tree for header elements (the DOM2
464
+ // nodeIterator API would be a better technique but not supported by all
465
+ // browsers).
466
+ var iterate = function (el) {
467
+ for (var i = el.firstChild; i != null; i = i.nextSibling) {
468
+ if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
469
+ var mo = re.exec(i.tagName);
470
+ if (mo && (i.getAttribute("class") || i.getAttribute("className")) != "float") {
471
+ result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
472
+ }
473
+ iterate(i);
474
+ }
389
475
  }
390
476
  }
477
+ iterate(el);
478
+ return result;
391
479
  }
392
- iterate(el);
393
- return result;
394
- }
395
480
 
396
- // This function does the work. toclevels = 1..4.
397
- function generateToc(toclevels) {
398
481
  var toc = document.getElementById("toc");
399
- var entries = tocEntries(document.getElementsByTagName("body")[0], toclevels);
482
+ var entries = tocEntries(document.getElementById("content"), toclevels);
400
483
  for (var i = 0; i < entries.length; ++i) {
401
484
  var entry = entries[i];
402
485
  if (entry.element.id == "")
403
- entry.element.id = "toc" + i;
486
+ entry.element.id = "_toc_" + i;
404
487
  var a = document.createElement("a");
405
488
  a.href = "#" + entry.element.id;
406
489
  a.appendChild(document.createTextNode(entry.text));
@@ -410,7 +493,58 @@ function generateToc(toclevels) {
410
493
  toc.appendChild(div);
411
494
  }
412
495
  if (entries.length == 0)
413
- document.getElementById("header").removeChild(toc);
496
+ toc.parentNode.removeChild(toc);
497
+ },
498
+
499
+
500
+ /////////////////////////////////////////////////////////////////////
501
+ // Footnotes generator
502
+ /////////////////////////////////////////////////////////////////////
503
+
504
+ /* Based on footnote generation code from:
505
+ * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html
506
+ */
507
+
508
+ footnotes: function () {
509
+ var cont = document.getElementById("content");
510
+ var noteholder = document.getElementById("footnotes");
511
+ var spans = cont.getElementsByTagName("span");
512
+ var refs = {};
513
+ var n = 0;
514
+ for (i=0; i<spans.length; i++) {
515
+ if (spans[i].className == "footnote") {
516
+ n++;
517
+ // Use [\s\S] in place of . so multi-line matches work.
518
+ // Because JavaScript has no s (dotall) regex flag.
519
+ note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
520
+ noteholder.innerHTML +=
521
+ "<div class='footnote' id='_footnote_" + n + "'>" +
522
+ "<a href='#_footnoteref_" + n + "' title='Return to text'>" +
523
+ n + "</a>. " + note + "</div>";
524
+ spans[i].innerHTML =
525
+ "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
526
+ "' title='View footnote' class='footnote'>" + n + "</a>]";
527
+ var id =spans[i].getAttribute("id");
528
+ if (id != null) refs["#"+id] = n;
529
+ }
530
+ }
531
+ if (n == 0)
532
+ noteholder.parentNode.removeChild(noteholder);
533
+ else {
534
+ // Process footnoterefs.
535
+ for (i=0; i<spans.length; i++) {
536
+ if (spans[i].className == "footnoteref") {
537
+ var href = spans[i].getElementsByTagName("a")[0].getAttribute("href");
538
+ href = href.match(/#.*/)[0]; // Because IE return full URL.
539
+ n = refs[href];
540
+ spans[i].innerHTML =
541
+ "[<a href='#_footnote_" + n +
542
+ "' title='View footnote' class='footnote'>" + n + "</a>]";
543
+ }
544
+ }
545
+ }
546
+ }
547
+
414
548
  }
415
549
  /*]]>*/
416
550
  </script>
@@ -423,6 +557,7 @@ function generateToc(toclevels) {
423
557
  <noscript><p><b>JavaScript must be enabled in your browser to display the table of contents.</b></p></noscript>
424
558
  </div>
425
559
  </div>
560
+ <div id="content">
426
561
  <div id="preamble">
427
562
  <div class="sectionbody">
428
563
  <div class="paragraph"><p><span class="image">
@@ -497,7 +632,7 @@ if it doesn&#8217;t.</p></div>
497
632
  </div>
498
633
  <h2 id="install_passenger">2. Installing Phusion Passenger</h2>
499
634
  <div class="sectionbody">
500
- <h3 id="_overview">2.1. Overview</h3>
635
+ <h3 id="_overview">2.1. Overview</h3><div style="clear:left"></div>
501
636
  <div class="paragraph"><p>As you might already know, Nginx does not support loadable modules, in contrast
502
637
  to most other web servers (e.g. Apache). Therefore, to install Phusion Passenger
503
638
  for Nginx, one must recompile and reinstall Nginx with Phusion Passenger support.
@@ -531,7 +666,7 @@ as <em>root</em>. If the installer fails because of permission errors, it will t
531
666
  you.</td>
532
667
  </tr></table>
533
668
  </div>
534
- <h3 id="specifying_ruby_installation">2.2. Specifying the correct Ruby installation</h3>
669
+ <h3 id="specifying_ruby_installation">2.2. Specifying the correct Ruby installation</h3><div style="clear:left"></div>
535
670
  <div class="paragraph"><p>If your system has multiple Ruby installations&#8201;&#8212;&#8201;which is likely the case on
536
671
  MacOS X, or if you&#8217;ve also installed
537
672
  <a href="http://www.rubyenterpriseedition.com">Ruby Enterprise Edition</a>&#8201;&#8212;&#8201;then you
@@ -559,7 +694,7 @@ following Ruby installations:</p></div>
559
694
  <div class="content">
560
695
  <pre><tt>export PATH=/opt/myruby/bin:$PATH</tt></pre>
561
696
  </div></div>
562
- <h3 id="_installing_phusion_passenger_for_nginx_through_the_installer">2.3. Installing Phusion Passenger for Nginx through the installer</h3>
697
+ <h3 id="_installing_phusion_passenger_for_nginx_through_the_installer">2.3. Installing Phusion Passenger for Nginx through the installer</h3><div style="clear:left"></div>
563
698
  <h4 id="_obtaining_the_phusion_passenger_files_and_running_the_installer">2.3.1. Obtaining the Phusion Passenger files and running the installer</h4>
564
699
  <div class="paragraph"><p>You must obtain the Phusion Passenger files in order to run the installer.
565
700
  This can be done either by installing the Phusion Passenger gem, or by
@@ -608,7 +743,7 @@ then you can do so by passing various answers to the installer through command
608
743
  line options.</p></div>
609
744
  <div class="paragraph"><p>Please run the installer with <tt>--help</tt> for a list of available command line
610
745
  options.</p></div>
611
- <h3 id="_installing_phusion_passenger_for_nginx_manually">2.4. Installing Phusion Passenger for Nginx manually</h3>
746
+ <h3 id="_installing_phusion_passenger_for_nginx_manually">2.4. Installing Phusion Passenger for Nginx manually</h3><div style="clear:left"></div>
612
747
  <div class="paragraph"><p>You can also install Phusion Passenger the way you install any other Nginx module.
613
748
  To do this, run Nginx&#8217;s configure script with <tt>--add-module=/path-to-passenger-root/ext/nginx</tt>.</p></div>
614
749
  <div class="paragraph"><p>If you installed Phusion Passenger via the gem, then <em>path-to-passenger-root</em>
@@ -641,7 +776,7 @@ are run, is &#8220;production&#8221;. You can change this by changing the
641
776
  <a href="#RailsEnv">rails_env</a> configuration option.</td>
642
777
  </tr></table>
643
778
  </div>
644
- <h3 id="_deploying_to_a_virtual_host_8217_s_root">3.1. Deploying to a virtual host&#8217;s root</h3>
779
+ <h3 id="_deploying_to_a_virtual_host_8217_s_root">3.1. Deploying to a virtual host&#8217;s root</h3><div style="clear:left"></div>
645
780
  <div class="paragraph"><p>Add a <em>server</em> virtual host entry to your Nginx configuration file. The virtual
646
781
  host&#8217;s root must point to your Ruby on Rails application&#8217;s <em>public</em> folder.</p></div>
647
782
  <div class="paragraph"><p>Inside the <em>server</em> block, set <em>passenger_enabled on</em>.</p></div>
@@ -662,7 +797,7 @@ host&#8217;s root must point to your Ruby on Rails application&#8217;s <em>publi
662
797
  }</tt></pre>
663
798
  </div></div>
664
799
  <div class="paragraph"><p>Then restart Nginx. The application has now been deployed.</p></div>
665
- <h3 id="deploying_rails_to_sub_uri">3.2. Deploying to a sub URI</h3>
800
+ <h3 id="deploying_rails_to_sub_uri">3.2. Deploying to a sub URI</h3><div style="clear:left"></div>
666
801
  <div class="paragraph"><p>Suppose that you already have a <em>server</em> virtual host entry:</p></div>
667
802
  <div class="listingblock">
668
803
  <div class="content">
@@ -725,7 +860,7 @@ option to the <em>server</em> block:</p></div>
725
860
  </td>
726
861
  </tr></table>
727
862
  </div>
728
- <h3 id="_redeploying_restarting_the_ruby_on_rails_application">3.3. Redeploying (restarting the Ruby on Rails application)</h3>
863
+ <h3 id="_redeploying_restarting_the_ruby_on_rails_application">3.3. Redeploying (restarting the Ruby on Rails application)</h3><div style="clear:left"></div>
729
864
  <div class="paragraph"><p>Deploying a new version of a Ruby on Rails application is as simple as
730
865
  re-uploading the application files, and restarting the application.</p></div>
731
866
  <div class="paragraph"><p>There are two ways to restart the application:</p></div>
@@ -753,12 +888,12 @@ command line:</p></div>
753
888
  is not automatically deleted. Phusion Passenger checks whether the timestamp
754
889
  of this file has changed in order to determine whether the application should
755
890
  be restarted.</p></div>
756
- <h3 id="_migrations">3.4. Migrations</h3>
891
+ <h3 id="_migrations">3.4. Migrations</h3><div style="clear:left"></div>
757
892
  <div class="paragraph"><p>Phusion Passenger is not related to Ruby on Rails migrations in any way. To
758
893
  run migrations on your deployment server, please login to your deployment
759
894
  server (e.g. with <em>ssh</em>) and type <tt>rake db:migrate RAILS_ENV=production</tt> in
760
895
  a shell console, just like one would normally run migrations.</p></div>
761
- <h3 id="_capistrano_integration">3.5. Capistrano integration</h3>
896
+ <h3 id="_capistrano_integration">3.5. Capistrano integration</h3><div style="clear:left"></div>
762
897
  <div class="paragraph"><p>See <a href="#capistrano">Capistrano recipe</a>.</p></div>
763
898
  </div>
764
899
  <h2 id="deploying_a_rack_app">4. Deploying a Rack-based Ruby application</h2>
@@ -812,7 +947,7 @@ are run, is &#8220;production&#8221;. You can change this by changing the
812
947
  <a href="#RackEnv">rack_env</a> configuration option.</td>
813
948
  </tr></table>
814
949
  </div>
815
- <h3 id="_tutorial_example_writing_and_deploying_a_hello_world_rack_application">4.1. Tutorial/example: writing and deploying a Hello World Rack application</h3>
950
+ <h3 id="_tutorial_example_writing_and_deploying_a_hello_world_rack_application">4.1. Tutorial/example: writing and deploying a Hello World Rack application</h3><div style="clear:left"></div>
816
951
  <div class="paragraph"><p>First we create a Phusion Passenger-compliant Rack directory structure:</p></div>
817
952
  <div class="listingblock">
818
953
  <div class="content">
@@ -849,7 +984,7 @@ the Apache configuration file:</p></div>
849
984
  </div></div>
850
985
  <div class="paragraph"><p>And we&#8217;re done! After an Nginx restart, the above Rack application will be available
851
986
  under the URL <em>http://www.rackexample.com/</em>.</p></div>
852
- <h3 id="_deploying_to_a_virtual_host_8217_s_root_2">4.2. Deploying to a virtual host&#8217;s root</h3>
987
+ <h3 id="_deploying_to_a_virtual_host_8217_s_root_2">4.2. Deploying to a virtual host&#8217;s root</h3><div style="clear:left"></div>
853
988
  <div class="paragraph"><p>Add a <em>server</em> virtual host entry to your Nginx configuration file. The virtual host&#8217;s
854
989
  root must point to your Rack application&#8217;s <em>public</em> folder. You must also set
855
990
  <em>passenger_enabled on</em> in the <em>server</em> block.</p></div>
@@ -868,7 +1003,7 @@ root must point to your Rack application&#8217;s <em>public</em> folder. You mus
868
1003
  }</tt></pre>
869
1004
  </div></div>
870
1005
  <div class="paragraph"><p>Then restart Nginx. The application has now been deployed.</p></div>
871
- <h3 id="deploying_rack_to_sub_uri">4.3. Deploying to a sub URI</h3>
1006
+ <h3 id="deploying_rack_to_sub_uri">4.3. Deploying to a sub URI</h3><div style="clear:left"></div>
872
1007
  <div class="paragraph"><p>Suppose that you already have a virtual host:</p></div>
873
1008
  <div class="listingblock">
874
1009
  <div class="content">
@@ -932,7 +1067,7 @@ option to the <em>server</em> block:</p></div>
932
1067
  </td>
933
1068
  </tr></table>
934
1069
  </div>
935
- <h3 id="_redeploying_restarting_the_rack_application">4.4. Redeploying (restarting the Rack application)</h3>
1070
+ <h3 id="_redeploying_restarting_the_rack_application">4.4. Redeploying (restarting the Rack application)</h3><div style="clear:left"></div>
936
1071
  <div class="paragraph"><p>Deploying a new version of a Rack application is as simple as
937
1072
  re-uploading the application files, and restarting the application.</p></div>
938
1073
  <div class="paragraph"><p>There are two ways to restart the application:</p></div>
@@ -956,7 +1091,7 @@ command line:</p></div>
956
1091
  <div class="content">
957
1092
  <pre><tt>touch /webapps/rackapp/tmp/restart.txt</tt></pre>
958
1093
  </div></div>
959
- <h3 id="_rackup_specifications_for_various_web_frameworks">4.5. Rackup specifications for various web frameworks</h3>
1094
+ <h3 id="_rackup_specifications_for_various_web_frameworks">4.5. Rackup specifications for various web frameworks</h3><div style="clear:left"></div>
960
1095
  <div class="paragraph"><p>This subsection shows example <em>config.ru</em> files for various web frameworks.</p></div>
961
1096
  <h4 id="_camping">4.5.1. Camping</h4>
962
1097
  <div class="listingblock">
@@ -1034,7 +1169,7 @@ run Sinatra::Application</tt></pre>
1034
1169
  Nevertheless, the system administrator may be interested in changing
1035
1170
  Phusion Passenger&#8217;s behavior. Phusion Passenger supports the following configuration
1036
1171
  options in the Nginx configuration file:</p></div>
1037
- <h3 id="_passenger_root_lt_directory_gt">5.1. passenger_root &lt;directory&gt;</h3>
1172
+ <h3 id="_passenger_root_lt_directory_gt">5.1. passenger_root &lt;directory&gt;</h3><div style="clear:left"></div>
1038
1173
  <div class="paragraph"><p>The location to the Phusion Passenger root directory. This configuration option
1039
1174
  is essential to Phusion Passenger, and allows Phusion Passenger to locate its own
1040
1175
  data files. The correct value is given by the installer.</p></div>
@@ -1042,7 +1177,7 @@ data files. The correct value is given by the installer.</p></div>
1042
1177
  this option as well. Please read
1043
1178
  <a href="#moving_phusion_passenger">Moving Phusion Passenger to a different directory</a> for more information.</p></div>
1044
1179
  <div class="paragraph"><p>This required option may only occur once, in the <em>http</em> configuration block.</p></div>
1045
- <h3 id="_passenger_log_level_lt_integer_gt">5.2. passenger_log_level &lt;integer&gt;</h3>
1180
+ <h3 id="_passenger_log_level_lt_integer_gt">5.2. passenger_log_level &lt;integer&gt;</h3><div style="clear:left"></div>
1046
1181
  <div class="paragraph"><p>This option allows one to specify how much information Phusion Passenger should
1047
1182
  write to the Apache error log file. A higher log level value means that more
1048
1183
  information will be logged.</p></div>
@@ -1073,11 +1208,11 @@ information will be logged.</p></div>
1073
1208
  </ul></div>
1074
1209
  <div class="paragraph"><p>This option may only occur once, in the <em>http</em> configuration block.
1075
1210
  The default is <em>0</em>.</p></div>
1076
- <h3 id="_passenger_ruby_lt_filename_gt">5.3. passenger_ruby &lt;filename&gt;</h3>
1211
+ <h3 id="_passenger_ruby_lt_filename_gt">5.3. passenger_ruby &lt;filename&gt;</h3><div style="clear:left"></div>
1077
1212
  <div class="paragraph"><p>This option allows one to specify the Ruby interpreter to use.</p></div>
1078
1213
  <div class="paragraph"><p>This option may only occur once, in the <em>http</em> configuration block.
1079
1214
  The default is <em>ruby</em>.</p></div>
1080
- <h3 id="PassengerUseGlobalQueue">5.4. passenger_use_global_queue &lt;on|off&gt;</h3>
1215
+ <h3 id="PassengerUseGlobalQueue">5.4. passenger_use_global_queue &lt;on|off&gt;</h3><div style="clear:left"></div>
1081
1216
  <div class="paragraph"><p>Turns the use of global queuing on or off.</p></div>
1082
1217
  <div class="paragraph"><p>This option may occur in the following places:</p></div>
1083
1218
  <div class="ulist"><ul>
@@ -1171,17 +1306,17 @@ process that becomes available will take from the queue, and so this
1171
1306
  <div class="paragraph"><p>Turning global queuing off will yield a minor performance improvement (about 5%,
1172
1307
  depending on how fast/slow your web application is), which is why it&#8217;s off by
1173
1308
  default.</p></div>
1174
- <h3 id="PassengerUserSwitching">5.5. passenger_user_switching &lt;on|off&gt;</h3>
1309
+ <h3 id="PassengerUserSwitching">5.5. passenger_user_switching &lt;on|off&gt;</h3><div style="clear:left"></div>
1175
1310
  <div class="paragraph"><p>Whether to enable <a href="#user_switching">user switching support</a>.</p></div>
1176
1311
  <div class="paragraph"><p>This option may only occur once, in the <em>http</em> configuration block.
1177
1312
  The default value is <em>on</em>.</p></div>
1178
- <h3 id="PassengerDefaultUser">5.6. passenger_default_user &lt;username&gt;</h3>
1313
+ <h3 id="PassengerDefaultUser">5.6. passenger_default_user &lt;username&gt;</h3><div style="clear:left"></div>
1179
1314
  <div class="paragraph"><p>Phusion Passenger enables <a href="#user_switching">user switching support</a> by default.
1180
1315
  This configuration option allows one to specify which user Rails/Rack
1181
1316
  applications must run as, if user switching fails or is disabled.</p></div>
1182
1317
  <div class="paragraph"><p>This option may only occur once, in the <em>http</em> configuration block.
1183
1318
  The default value is <em>nobody</em>.</p></div>
1184
- <h3 id="_important_deployment_options">5.7. Important deployment options</h3>
1319
+ <h3 id="_important_deployment_options">5.7. Important deployment options</h3><div style="clear:left"></div>
1185
1320
  <h4 id="_passenger_enabled_lt_on_off_gt">5.7.1. passenger_enabled &lt;on|off&gt;</h4>
1186
1321
  <div class="paragraph"><p>This option may be specified in a <em>server</em> configuration block, a
1187
1322
  <em>location</em> configuration block or an <em>if</em> configuration scope, to
@@ -1216,7 +1351,7 @@ In an <em>if</em> configuration scope.
1216
1351
  </p>
1217
1352
  </li>
1218
1353
  </ul></div>
1219
- <h3 id="_resource_control_and_optimization_options">5.8. Resource control and optimization options</h3>
1354
+ <h3 id="_resource_control_and_optimization_options">5.8. Resource control and optimization options</h3><div style="clear:left"></div>
1220
1355
  <h4 id="PassengerMaxPoolSize">5.8.1. passenger_max_pool_size &lt;integer&gt;</h4>
1221
1356
  <div class="paragraph"><p>The maximum number of Ruby on Rails or Rack application instances that may
1222
1357
  be simultaneously active. A larger number results in higher memory usage,
@@ -1272,7 +1407,7 @@ recommended if you&#8217;re on a non-shared host that&#8217;s only running a few
1272
1407
  applications, each which must be available at all times.</p></div>
1273
1408
  <div class="paragraph"><p>This option may only occur once, in the <em>http</em> configuration block.
1274
1409
  The default value is <em>300</em>.</p></div>
1275
- <h3 id="_ruby_on_rails_specific_options">5.9. Ruby on Rails-specific options</h3>
1410
+ <h3 id="_ruby_on_rails_specific_options">5.9. Ruby on Rails-specific options</h3><div style="clear:left"></div>
1276
1411
  <h4 id="RailsEnv">5.9.1. rails_env &lt;string&gt;</h4>
1277
1412
  <div class="paragraph"><p>This option allows one to specify the default <tt>RAILS_ENV</tt> value.</p></div>
1278
1413
  <div class="paragraph"><p>This option may occur in the following places:</p></div>
@@ -1305,7 +1440,7 @@ In an <em>if</em> configuration scope.
1305
1440
  <div class="paragraph"><p>This subsection attempts to describe spawn methods, but it&#8217;s okay if you don&#8217;t (want to)
1306
1441
  understand it, as it&#8217;s mostly a technical detail. You can basically follow this rule of thumb:</p></div>
1307
1442
  <div class="sidebarblock">
1308
- <div class="content">
1443
+ <div class="sidebar-content">
1309
1444
  <div class="paragraph"><p>If your application works on Mongrel, but not on Phusion Passenger, then set
1310
1445
  <tt>rails_spawn_method</tt> to <em>conservative</em>. Otherwise, leave it at <em>smart-lv2</em> (the default).</p></div>
1311
1446
  </div></div>
@@ -1471,7 +1606,7 @@ In an <em>if</em> configuration scope.
1471
1606
  </li>
1472
1607
  </ul></div>
1473
1608
  <div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>600</em> (10 minutes).</p></div>
1474
- <h3 id="_rack_specific_options">5.10. Rack-specific options</h3>
1609
+ <h3 id="_rack_specific_options">5.10. Rack-specific options</h3><div style="clear:left"></div>
1475
1610
  <h4 id="RackEnv">5.10.1. rack_env &lt;string&gt;</h4>
1476
1611
  <div class="paragraph"><p>This option allows one to specify the default <tt>RACK_ENV</tt> value.</p></div>
1477
1612
  <div class="paragraph"><p>This option may occur in the following places:</p></div>
@@ -1498,7 +1633,7 @@ In an <em>if</em> configuration scope.
1498
1633
  <div class="sectionbody">
1499
1634
  <div class="paragraph"><p>Phusion Passenger provides a set of tools, which are useful for system analysis,
1500
1635
  maintenance and troubleshooting.</p></div>
1501
- <h3 id="_inspecting_memory_usage">6.1. Inspecting memory usage</h3>
1636
+ <h3 id="_inspecting_memory_usage">6.1. Inspecting memory usage</h3><div style="clear:left"></div>
1502
1637
  <div class="paragraph"><p>Process inspection tools such as <tt>ps</tt> and <tt>top</tt> are useful, but they
1503
1638
  <a href="http://groups.google.com/group/phusion-passenger/msg/1fd1c233456d3180">rarely show the correct memory usage</a>.
1504
1639
  The real memory usage is usually lower than what <tt>ps</tt> and <tt>top</tt> report.</p></div>
@@ -1548,7 +1683,7 @@ don&#8217;t provide facilities for determining processes' private dirty RSS. On
1548
1683
  the Resident Set Size is reported instead.</td>
1549
1684
  </tr></table>
1550
1685
  </div>
1551
- <h3 id="_inspecting_phusion_passenger_8217_s_internal_status">6.2. Inspecting Phusion Passenger&#8217;s internal status</h3>
1686
+ <h3 id="_inspecting_phusion_passenger_8217_s_internal_status">6.2. Inspecting Phusion Passenger&#8217;s internal status</h3><div style="clear:left"></div>
1552
1687
  <div class="paragraph"><p>One can inspect Phusion Passenger&#8217;s internal status with the tool <tt>passenger-status</tt>.
1553
1688
  This tool must typically be run as root. For example:</p></div>
1554
1689
  <div class="listingblock">
@@ -1675,7 +1810,7 @@ Your application is frozen, i.e. has stopped responding. See
1675
1810
  </p>
1676
1811
  </li>
1677
1812
  </ol></div>
1678
- <h3 id="debugging_frozen">6.3. Debugging frozen applications</h3>
1813
+ <h3 id="debugging_frozen">6.3. Debugging frozen applications</h3><div style="clear:left"></div>
1679
1814
  <div class="paragraph"><p>If one of your application instances is frozen (stopped responding), then you
1680
1815
  can figure out where it is frozen by killing it with <em>SIGABRT</em>. This will cause the
1681
1816
  application to raise an exception, with a backtrace.</p></div>
@@ -1698,7 +1833,7 @@ will restart killed application instances, as if nothing bad happened.</td>
1698
1833
  </div>
1699
1834
  <h2 id="_tips">7. Tips</h2>
1700
1835
  <div class="sectionbody">
1701
- <h3 id="user_switching">7.1. User switching (security)</h3>
1836
+ <h3 id="user_switching">7.1. User switching (security)</h3><div style="clear:left"></div>
1702
1837
  <div class="paragraph"><p>There is a problem that plagues most PHP web hosts, namely the fact that all PHP
1703
1838
  applications are run in the same user context as the web server. So for
1704
1839
  example, Joe&#8217;s PHP application will be able to read Jane&#8217;s PHP application&#8217;s
@@ -1737,12 +1872,12 @@ Under no circumstances will applications be run as <em>root</em>. If
1737
1872
  <div class="paragraph"><p>User switching can be disabled with the
1738
1873
  <a href="#PassengerUserSwitching">PassengerUserSwitching (Apache)</a>/<a href="#PassengerUserSwitching">passenger_user_switching (Nginx)</a>
1739
1874
  option.</p></div>
1740
- <h3 id="reducing_memory_usage">7.2. Reducing memory consumption of Ruby on Rails applications by 33%</h3>
1875
+ <h3 id="reducing_memory_usage">7.2. Reducing memory consumption of Ruby on Rails applications by 33%</h3><div style="clear:left"></div>
1741
1876
  <div class="paragraph"><p>Is it possible to reduce memory consumption of your Rails applications by 33% on average,
1742
1877
  by using <a href="http://www.rubyenterpriseedition.com/">Ruby Enterprise Edition</a>.
1743
1878
  Please visit the website for details.</p></div>
1744
1879
  <div class="paragraph"><p>Note that this feature does not apply to Rack applications.</p></div>
1745
- <h3 id="capistrano">7.3. Capistrano recipe</h3>
1880
+ <h3 id="capistrano">7.3. Capistrano recipe</h3><div style="clear:left"></div>
1746
1881
  <div class="paragraph"><p>Phusion Passenger can be combined with <a href="http://capify.org/">Capistrano</a>.
1747
1882
  The following Capistrano recipe demonstrates Phusion Passenger support.
1748
1883
  It assumes that you&#8217;re using Git as version control system.</p></div>
@@ -1774,7 +1909,7 @@ namespace :deploy do
1774
1909
  end
1775
1910
  end</tt></pre>
1776
1911
  </div></div>
1777
- <h3 id="moving_phusion_passenger">7.4. Moving Phusion Passenger to a different directory</h3>
1912
+ <h3 id="moving_phusion_passenger">7.4. Moving Phusion Passenger to a different directory</h3><div style="clear:left"></div>
1778
1913
  <div class="paragraph"><p>It is possible to relocate the Phusion Passenger files to a different directory. It
1779
1914
  involves two steps:</p></div>
1780
1915
  <div class="olist arabic"><ol class="arabic">
@@ -1811,7 +1946,7 @@ Edit your Apache configuration file, and set:
1811
1946
  </div></div>
1812
1947
  </li>
1813
1948
  </ol></div>
1814
- <h3 id="_installing_multiple_ruby_on_rails_versions">7.5. Installing multiple Ruby on Rails versions</h3>
1949
+ <h3 id="_installing_multiple_ruby_on_rails_versions">7.5. Installing multiple Ruby on Rails versions</h3><div style="clear:left"></div>
1815
1950
  <div class="paragraph"><p>Each Ruby on Rails applications that are going to be deployed may require a
1816
1951
  specific Ruby on Rails version. You can install a specific version with
1817
1952
  this command:</p></div>
@@ -1822,7 +1957,7 @@ this command:</p></div>
1822
1957
  <div class="paragraph"><p>where <em>X.X.X</em> is the version number of Ruby on Rails.</p></div>
1823
1958
  <div class="paragraph"><p>All of these versions will exist in parallel, and will not conflict with each
1824
1959
  other. Phusion Passenger will automatically make use of the correct version.</p></div>
1825
- <h3 id="_making_the_application_restart_after_each_request">7.6. Making the application restart after each request</h3>
1960
+ <h3 id="_making_the_application_restart_after_each_request">7.6. Making the application restart after each request</h3><div style="clear:left"></div>
1826
1961
  <div class="paragraph"><p>In some situations it might be desirable to restart the web application after
1827
1962
  each request, for example when developing a non-Rails application that doesn&#8217;t
1828
1963
  support code reloading, or when developing a web framework.</p></div>
@@ -1843,7 +1978,7 @@ or when you&#8217;re not developing a Rails application and your web framework
1843
1978
  does not support code reloading.</td>
1844
1979
  </tr></table>
1845
1980
  </div>
1846
- <h3 id="sub_uri_deployment_uri_fix">7.7. How to fix broken images/CSS/JavaScript URIs in sub-URI deployments</h3>
1981
+ <h3 id="sub_uri_deployment_uri_fix">7.7. How to fix broken images/CSS/JavaScript URIs in sub-URI deployments</h3><div style="clear:left"></div>
1847
1982
  <div class="paragraph"><p>Some people experience broken images and other broken static assets when they
1848
1983
  deploy their application to a sub-URI (i.e. <em>http://mysite.com/railsapp/</em>).
1849
1984
  The reason for this usually is that you used a
@@ -1899,7 +2034,7 @@ Attribution-Share Alike 3.0 Unported License</a>.</p></div>
1899
2034
  </div>
1900
2035
  <h2 id="_appendix_b_terminology">9. Appendix B: Terminology</h2>
1901
2036
  <div class="sectionbody">
1902
- <h3 id="application_root">9.1. Application root</h3>
2037
+ <h3 id="application_root">9.1. Application root</h3><div style="clear:left"></div>
1903
2038
  <div class="paragraph"><p>The root directory of an application that&#8217;s served by Phusion Passenger.</p></div>
1904
2039
  <div class="paragraph"><p>In case of Ruby on Rails applications, this is the directory that contains
1905
2040
  <em>Rakefile</em>, <em>app/</em>, <em>config/</em>, <em>public/</em>, etc. In other words, the directory
@@ -1966,7 +2101,7 @@ processes.</p></div>
1966
2101
  <div class="paragraph"><p>While this may sound simple, there&#8217;s not just one way to spawn worker processes.
1967
2102
  Let&#8217;s go over the different spawning methods. For simplicity&#8217;s sake, let&#8217;s
1968
2103
  assume that we&#8217;re only talking about Ruby on Rails applications.</p></div>
1969
- <h3 id="_the_most_straightforward_and_traditional_way_conservative_spawning">10.1. The most straightforward and traditional way: conservative spawning</h3>
2104
+ <h3 id="_the_most_straightforward_and_traditional_way_conservative_spawning">10.1. The most straightforward and traditional way: conservative spawning</h3><div style="clear:left"></div>
1970
2105
  <div class="paragraph"><p>Phusion Passenger could create a new Ruby process, which will then load the
1971
2106
  Rails application along with the entire Rails framework. This process will then
1972
2107
  enter an request handling main loop.</p></div>
@@ -1981,7 +2116,7 @@ programmers jargon, mongrel_cluster creates new Ruby processes by forking the
1981
2116
  current process and exec()-ing a new Ruby interpreter. Phusion Passenger on the
1982
2117
  other hand creates processes that reuse the already loaded Ruby interpreter. In
1983
2118
  programmers jargon, Phusion Passenger calls fork(), but not exec().</p></div>
1984
- <h3 id="_the_smart_spawning_method">10.2. The smart spawning method</h3>
2119
+ <h3 id="_the_smart_spawning_method">10.2. The smart spawning method</h3><div style="clear:left"></div>
1985
2120
  <div class="admonitionblock">
1986
2121
  <table><tr>
1987
2122
  <td class="icon">
@@ -1995,7 +2130,7 @@ programmers jargon, Phusion Passenger calls fork(), but not exec().</p></div>
1995
2130
  because each worker process has its own private copy of the Rails application
1996
2131
  as well as the Rails framework. This wastes memory as well as startup time.</p></div>
1997
2132
  <div class="paragraph"><p><span class="image">
1998
- <img src="images/conservative_spawning.png" alt="Worker processes and conservative spawning" title="Worker processes and conservative spawning" />
2133
+ <img src="images/conservative_spawning.png" alt="Worker processes and conservative spawning" />
1999
2134
  </span><br />
2000
2135
  <em>Figure: Worker processes and conservative spawning. Each worker process has its
2001
2136
  own private copy of the application code and Rails framework code.</em></p></div>
@@ -2088,7 +2223,7 @@ process).</p></div>
2088
2223
  assuming that your Ruby interpreter is <a href="#reducing_memory_usage">copy-on-write friendly</a>.</p></div>
2089
2224
  <div class="paragraph"><p>Of course, smart spawning is not without gotchas. But if you understand the
2090
2225
  gotchas you can easily reap the benefits of smart spawning.</p></div>
2091
- <h3 id="_smart_spawning_gotcha_1_unintential_file_descriptor_sharing">10.3. Smart spawning gotcha #1: unintential file descriptor sharing</h3>
2226
+ <h3 id="_smart_spawning_gotcha_1_unintential_file_descriptor_sharing">10.3. Smart spawning gotcha #1: unintential file descriptor sharing</h3><div style="clear:left"></div>
2092
2227
  <div class="paragraph"><p>Because worker processes are created by forking from an ApplicationSpawner
2093
2228
  server, it will share all file descriptors that are opened by the
2094
2229
  ApplicationSpawner server. (This is part of the semantics of the Unix
@@ -2219,7 +2354,7 @@ data in the log file is interleaved.</p></div>
2219
2354
  must synchronize write access via an inter-process synchronization mechanism,
2220
2355
  such as file locks. Reopening the log file, like you would have done in the
2221
2356
  Memcached example, doesn&#8217;t help.</p></div>
2222
- <h3 id="_smart_spawning_gotcha_2_the_need_to_revive_threads">10.4. Smart spawning gotcha #2: the need to revive threads</h3>
2357
+ <h3 id="_smart_spawning_gotcha_2_the_need_to_revive_threads">10.4. Smart spawning gotcha #2: the need to revive threads</h3><div style="clear:left"></div>
2223
2358
  <div class="paragraph"><p>Another part of the <em>fork()</em> system call&#8217;s semantics is the fact that threads
2224
2359
  disappear after a fork call. So if you&#8217;ve created any threads in environment.rb,
2225
2360
  then those threads will no longer be running in newly created worker process.
@@ -2240,7 +2375,7 @@ http://www.gnu.org/software/src-highlite -->
2240
2375
  <span style="font-weight: bold"><span style="color: #0000FF">end</span></span>
2241
2376
  <span style="font-weight: bold"><span style="color: #0000FF">end</span></span>
2242
2377
  <span style="font-weight: bold"><span style="color: #0000FF">end</span></span></tt></pre></div></div>
2243
- <h3 id="_smart_spawning_gotcha_3_code_load_order">10.5. Smart spawning gotcha #3: code load order</h3>
2378
+ <h3 id="_smart_spawning_gotcha_3_code_load_order">10.5. Smart spawning gotcha #3: code load order</h3><div style="clear:left"></div>
2244
2379
  <div class="paragraph"><p>This gotcha is only applicable to the <em>smart</em> spawn method, not the <em>smart-lv2</em>
2245
2380
  spawn method.</p></div>
2246
2381
  <div class="paragraph"><p>If your application expects the Rails framework to be not loaded during the
@@ -2257,9 +2392,11 @@ spawning is used, the patched version of <em>base.rb</em> is properly loaded. Wh
2257
2392
  because it was already loaded, so a subsequent <tt>require "active_record/base"</tt>
2258
2393
  has no effect.</p></div>
2259
2394
  </div>
2395
+ </div>
2396
+ <div id="footnotes"><hr /></div>
2260
2397
  <div id="footer">
2261
2398
  <div id="footer-text">
2262
- Last updated 2010-01-08 11:24:06 CEST
2399
+ Last updated 2010-02-22 13:16:14 CEST
2263
2400
  </div>
2264
2401
  </div>
2265
2402
  </body>