itsi 0.1.19 → 0.1.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (393) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +15 -0
  3. data/Cargo.lock +941 -241
  4. data/README.md +67 -55
  5. data/crates/itsi_server/Cargo.toml +3 -3
  6. data/crates/itsi_server/src/ruby_types/itsi_http_request.rs +2 -2
  7. data/crates/itsi_server/src/ruby_types/itsi_server/itsi_server_config.rs +150 -19
  8. data/crates/itsi_server/src/ruby_types/itsi_server.rs +1 -0
  9. data/crates/itsi_server/src/server/binds/listener.rs +34 -29
  10. data/crates/itsi_server/src/server/binds/tls/locked_dir_cache.rs +2 -2
  11. data/crates/itsi_server/src/server/binds/tls.rs +1 -1
  12. data/crates/itsi_server/src/server/middleware_stack/middleware.rs +33 -28
  13. data/crates/itsi_server/src/server/middleware_stack/middlewares/auth_jwt.rs +56 -3
  14. data/crates/itsi_server/src/server/middleware_stack/middlewares/csp.rs +179 -0
  15. data/crates/itsi_server/src/server/middleware_stack/middlewares/mod.rs +25 -2
  16. data/crates/itsi_server/src/server/middleware_stack/middlewares/ruby_app.rs +3 -3
  17. data/crates/itsi_server/src/server/middleware_stack/middlewares/static_assets.rs +2 -1
  18. data/crates/itsi_server/src/server/middleware_stack/mod.rs +32 -34
  19. data/crates/itsi_server/src/server/serve_strategy/cluster_mode.rs +10 -4
  20. data/crates/itsi_server/src/server/serve_strategy/single_mode.rs +30 -7
  21. data/crates/itsi_server/src/server/thread_worker.rs +2 -2
  22. data/crates/itsi_server/src/services/static_file_server.rs +30 -28
  23. data/crates/itsi_tracing/src/lib.rs +39 -8
  24. data/docker/Dockerfile +12 -0
  25. data/docs/content/_index.md +18 -10
  26. data/docs/content/acknowledgements/_index.md +43 -0
  27. data/docs/content/configuration/_index.md +98 -0
  28. data/docs/content/contact/_index.md +7 -0
  29. data/docs/content/faqs/_index.md +27 -0
  30. data/docs/content/features/_index.md +285 -0
  31. data/docs/content/getting_started/_index.md +70 -0
  32. data/docs/content/getting_started/local_development.md +40 -0
  33. data/docs/content/getting_started/logging.md +16 -0
  34. data/docs/content/getting_started/running_itsi_in_production.md +24 -0
  35. data/docs/content/itsi-server-100.png +0 -0
  36. data/docs/content/itsi_scheduler/_index.md +105 -0
  37. data/docs/content/itsi_scheduler/itsi-scheduler-100.png +0 -0
  38. data/docs/content/ruby-lsp.png +0 -0
  39. data/docs/content/ruby.svg +948 -0
  40. data/docs/data/icons.yaml +949 -0
  41. data/docs/hugo.yaml +27 -28
  42. data/fairytale.txt +34 -0
  43. data/gems/scheduler/Cargo.lock +46 -46
  44. data/gems/scheduler/README.md +53 -24
  45. data/gems/scheduler/itsi-scheduler-100.png +0 -0
  46. data/gems/scheduler/lib/itsi/scheduler/version.rb +1 -1
  47. data/gems/server/Cargo.lock +950 -239
  48. data/gems/server/README.md +2 -0
  49. data/gems/server/exe/itsi +5 -5
  50. data/gems/server/lib/itsi/server/config/config_helpers.rb +93 -0
  51. data/gems/server/lib/itsi/server/config/dsl.rb +81 -33
  52. data/gems/server/lib/itsi/server/config/known_paths/KitchensinkDirectories.txt +2346 -0
  53. data/gems/server/lib/itsi/server/config/known_paths/Randomfiles.txt +24 -0
  54. data/gems/server/lib/itsi/server/config/known_paths/UnixDotfiles.txt +52 -0
  55. data/gems/server/lib/itsi/server/config/known_paths/backdoors/ASP_CommonBackdoors.txt +29 -0
  56. data/gems/server/lib/itsi/server/config/known_paths/backdoors/bot_control_panels.txt +1668 -0
  57. data/gems/server/lib/itsi/server/config/known_paths/backdoors/shells.txt +1167 -0
  58. data/gems/server/lib/itsi/server/config/known_paths/cgi/CGI_HTTP_POST.txt +7 -0
  59. data/gems/server/lib/itsi/server/config/known_paths/cgi/CGI_HTTP_POST_Windows.txt +6 -0
  60. data/gems/server/lib/itsi/server/config/known_paths/cgi/CGI_Microsoft.txt +79 -0
  61. data/gems/server/lib/itsi/server/config/known_paths/cgi/CGI_XPlatform.txt +3948 -0
  62. data/gems/server/lib/itsi/server/config/known_paths/cms/README.md +5 -0
  63. data/gems/server/lib/itsi/server/config/known_paths/cms/drupal_plugins.txt +6320 -0
  64. data/gems/server/lib/itsi/server/config/known_paths/cms/drupal_themes.txt +828 -0
  65. data/gems/server/lib/itsi/server/config/known_paths/cms/joomla_plugins.txt +224 -0
  66. data/gems/server/lib/itsi/server/config/known_paths/cms/joomla_themes.txt +30 -0
  67. data/gems/server/lib/itsi/server/config/known_paths/cms/php-nuke.txt +2142 -0
  68. data/gems/server/lib/itsi/server/config/known_paths/cms/wordpress.txt +1566 -0
  69. data/gems/server/lib/itsi/server/config/known_paths/cms/wp_common_theme_files.txt +46 -0
  70. data/gems/server/lib/itsi/server/config/known_paths/cms/wp_plugins.txt +13366 -0
  71. data/gems/server/lib/itsi/server/config/known_paths/cms/wp_plugins_full.txt +68662 -0
  72. data/gems/server/lib/itsi/server/config/known_paths/cms/wp_plugins_top225.txt +225 -0
  73. data/gems/server/lib/itsi/server/config/known_paths/cms/wp_themes.readme +12 -0
  74. data/gems/server/lib/itsi/server/config/known_paths/cms/wp_themes.txt +7336 -0
  75. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/3CharExtBrute.txt +17576 -0
  76. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/CommonWebExtensions.txt +80 -0
  77. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/Extensions.Backup.txt +14 -0
  78. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/Extensions.Common.txt +865 -0
  79. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/Extensions.Compressed.txt +186 -0
  80. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/Extensions.Mostcommon.txt +30 -0
  81. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/Extensions.Skipfish.txt +93 -0
  82. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/WordlistSkipfish.txt +1918 -0
  83. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/copy_of.txt +8 -0
  84. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-directories-lowercase.txt +56180 -0
  85. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-directories.txt +62290 -0
  86. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-extensions-lowercase.txt +2367 -0
  87. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-extensions.txt +2450 -0
  88. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-files-lowercase.txt +35323 -0
  89. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-files.txt +37037 -0
  90. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-words-lowercase.txt +107982 -0
  91. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-large-words.txt +119600 -0
  92. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-directories-lowercase.txt +26593 -0
  93. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-directories.txt +30009 -0
  94. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-extensions-lowercase.txt +1233 -0
  95. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-extensions.txt +1289 -0
  96. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-files-lowercase.txt +16243 -0
  97. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-files.txt +17128 -0
  98. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-words-lowercase.txt +56293 -0
  99. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-medium-words.txt +63087 -0
  100. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-directories-lowercase.txt +17776 -0
  101. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-directories.txt +20122 -0
  102. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-extensions-lowercase.txt +914 -0
  103. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-extensions.txt +963 -0
  104. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-files-lowercase.txt +10848 -0
  105. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-files.txt +11424 -0
  106. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-words-lowercase.txt +38267 -0
  107. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/raft-small-words.txt +43003 -0
  108. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/spanish.txt +445 -0
  109. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/test_demo.txt +36 -0
  110. data/gems/server/lib/itsi/server/config/known_paths/filename-dirname-bruteforce/upload_variants.txt +44 -0
  111. data/gems/server/lib/itsi/server/config/known_paths/login-file-locations/Logins.txt +71 -0
  112. data/gems/server/lib/itsi/server/config/known_paths/login-file-locations/cfm.txt +294 -0
  113. data/gems/server/lib/itsi/server/config/known_paths/login-file-locations/html.txt +295 -0
  114. data/gems/server/lib/itsi/server/config/known_paths/login-file-locations/jsp.txt +294 -0
  115. data/gems/server/lib/itsi/server/config/known_paths/login-file-locations/php.txt +294 -0
  116. data/gems/server/lib/itsi/server/config/known_paths/login-file-locations/windows-asp.txt +294 -0
  117. data/gems/server/lib/itsi/server/config/known_paths/login-file-locations/windows-aspx.txt +294 -0
  118. data/gems/server/lib/itsi/server/config/known_paths/password-file-locations/Passwords.txt +47 -0
  119. data/gems/server/lib/itsi/server/config/known_paths/php/PHP.txt +30 -0
  120. data/gems/server/lib/itsi/server/config/known_paths/php/PHP_CommonBackdoors.txt +5 -0
  121. data/gems/server/lib/itsi/server/config/known_paths/proxy-conf.txt +31 -0
  122. data/gems/server/lib/itsi/server/config/known_paths/tftp.txt +79 -0
  123. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/ADFS.txt +86 -0
  124. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/AdobeXML.txt +16 -0
  125. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Apache.txt +101 -0
  126. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/ApacheTomcat.txt +47 -0
  127. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Apache_Axis.txt +16 -0
  128. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/ColdFusion.txt +111 -0
  129. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/FatwireCMS.txt +390 -0
  130. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Frontpage.txt +38 -0
  131. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/HP_System_Mgmt_Homepage.txt +239 -0
  132. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/HTTP_POST_Microsoft.txt +2 -0
  133. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Hyperion.txt +578 -0
  134. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/IIS.txt +187 -0
  135. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/JBoss.txt +5 -0
  136. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/JRun.txt +13 -0
  137. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/JavaServlets_Common.txt +3 -0
  138. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Joomla_exploitable.txt +1937 -0
  139. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/LotusNotes.txt +206 -0
  140. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Netware.txt +18 -0
  141. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Oracle9i.txt +60 -0
  142. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/OracleAppServer.txt +192 -0
  143. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/README.md +6 -0
  144. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Ruby_Rails.txt +121 -0
  145. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/SAP.txt +463 -0
  146. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Sharepoint.txt +1707 -0
  147. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/SiteMinder.txt +19 -0
  148. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/SunAppServerGlassfish.txt +51 -0
  149. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/SuniPlanet.txt +35 -0
  150. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Vignette.txt +73 -0
  151. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Weblogic.txt +160 -0
  152. data/gems/server/lib/itsi/server/config/known_paths/webservers-appservers/Websphere.txt +366 -0
  153. data/gems/server/lib/itsi/server/config/known_paths/wellknown-rfc5785.txt +30 -0
  154. data/gems/server/lib/itsi/server/config/known_paths.rb +17 -0
  155. data/gems/server/lib/itsi/server/config/middleware/_index.md +54 -0
  156. data/gems/server/lib/itsi/server/config/middleware/log_requests.md +63 -0
  157. data/gems/server/lib/itsi/server/config/middleware/log_requests.rb +33 -0
  158. data/gems/server/lib/itsi/server/config/middleware.rb +9 -0
  159. data/gems/server/lib/itsi/server/config/option.rb +9 -0
  160. data/gems/server/lib/itsi/server/config/options/_index.md +36 -0
  161. data/gems/server/lib/itsi/server/config/options/fiber_scheduler.md +35 -0
  162. data/gems/server/lib/itsi/server/config/options/fiber_scheduler.rb +18 -0
  163. data/gems/server/lib/itsi/server/config/options/threads.md +39 -0
  164. data/gems/server/lib/itsi/server/config/options/threads.rb +17 -0
  165. data/gems/server/lib/itsi/server/config/options/workers.md +43 -0
  166. data/gems/server/lib/itsi/server/config/options/workers.rb +17 -0
  167. data/gems/server/lib/itsi/server/config/typed_struct.rb +203 -0
  168. data/gems/server/lib/itsi/server/config.rb +124 -30
  169. data/gems/server/lib/itsi/server/signal_trap.rb +5 -1
  170. data/gems/server/lib/itsi/server/typed_handlers/source_parser.rb +1 -1
  171. data/gems/server/lib/itsi/server/version.rb +1 -1
  172. data/gems/server/lib/itsi/server.rb +27 -6
  173. data/gems/server/lib/ruby_lsp/itsi/addon.rb +64 -48
  174. data/gems/server/test/helpers/test_helper.rb +64 -5
  175. data/gems/server/test/middleware/test_log_requests.rb +17 -0
  176. data/gems/server/test/options/test_threads.rb +15 -0
  177. data/gems/server/test/options/test_workers.rb +18 -0
  178. data/gems/server/test/test_itsi_server.rb +81 -94
  179. data/itsi-scheduler-100.png +0 -0
  180. data/itsi-server-100.png +0 -0
  181. data/lib/itsi/version.rb +1 -1
  182. data/tasks.txt +36 -28
  183. metadata +147 -215
  184. data/crates/_index.md +0 -0
  185. data/crates/itsi_server/src/ruby_types/README.md +0 -21
  186. data/crates/itsi_server/test.md +0 -14
  187. data/docs/Itsi.rb +0 -17
  188. data/docs/content/about.md +0 -6
  189. data/docs/content/docs/_index.md +0 -18
  190. data/docs/content/docs/first-page.md +0 -9
  191. data/docs/content/docs/folder/_index.md +0 -10
  192. data/docs/content/docs/folder/leaf.md +0 -7
  193. data/foo/Itsi.rb +0 -122
  194. data/gems/_index.md +0 -18
  195. data/gems/scheduler/CHANGELOG.md +0 -5
  196. data/gems/scheduler/CODE_OF_CONDUCT.md +0 -139
  197. data/gems/scheduler/LICENSE.txt +0 -21
  198. data/gems/scheduler/_index.md +0 -7
  199. data/gems/server/CHANGELOG.md +0 -10
  200. data/gems/server/CODE_OF_CONDUCT.md +0 -139
  201. data/gems/server/LICENSE.txt +0 -21
  202. data/gems/server/_index.md +0 -6
  203. data/sandbox/README.md +0 -5
  204. data/sandbox/deploy/main.tf +0 -238
  205. data/sandbox/deploy/outputs.tf +0 -4
  206. data/sandbox/deploy/vars.tf +0 -11
  207. data/sandbox/falcon_benchmark/Gemfile +0 -10
  208. data/sandbox/falcon_benchmark/Gemfile.lock +0 -140
  209. data/sandbox/falcon_benchmark/config.ru +0 -54
  210. data/sandbox/itsi_file/Gemfile +0 -13
  211. data/sandbox/itsi_file/Gemfile.lock +0 -111
  212. data/sandbox/itsi_file/Itsi.rb +0 -474
  213. data/sandbox/itsi_file/call.json +0 -1
  214. data/sandbox/itsi_file/echo_client/Gemfile +0 -10
  215. data/sandbox/itsi_file/echo_client/Gemfile.lock +0 -27
  216. data/sandbox/itsi_file/echo_client/README.md +0 -95
  217. data/sandbox/itsi_file/echo_client/echo_client.rb +0 -164
  218. data/sandbox/itsi_file/echo_client/gen_proto.sh +0 -17
  219. data/sandbox/itsi_file/echo_client/lib/echo_pb.rb +0 -16
  220. data/sandbox/itsi_file/echo_client/lib/echo_services_pb.rb +0 -29
  221. data/sandbox/itsi_file/echo_client/run_client.rb +0 -64
  222. data/sandbox/itsi_file/echo_client/test_compressions.sh +0 -20
  223. data/sandbox/itsi_file/echo_service_nonitsi/Gemfile +0 -10
  224. data/sandbox/itsi_file/echo_service_nonitsi/Gemfile.lock +0 -79
  225. data/sandbox/itsi_file/echo_service_nonitsi/echo.proto +0 -26
  226. data/sandbox/itsi_file/echo_service_nonitsi/echo_pb.rb +0 -16
  227. data/sandbox/itsi_file/echo_service_nonitsi/echo_services_pb.rb +0 -29
  228. data/sandbox/itsi_file/echo_service_nonitsi/server.rb +0 -52
  229. data/sandbox/itsi_file/error.html +0 -2
  230. data/sandbox/itsi_file/organisations_controller.rb +0 -20
  231. data/sandbox/itsi_file/public/assets/image.png +0 -0
  232. data/sandbox/itsi_sandbox_async/Gemfile +0 -10
  233. data/sandbox/itsi_sandbox_async/Gemfile.lock +0 -69
  234. data/sandbox/itsi_sandbox_async/config.ru +0 -9
  235. data/sandbox/itsi_sandbox_hanami/.env +0 -2
  236. data/sandbox/itsi_sandbox_hanami/.gitignore +0 -6
  237. data/sandbox/itsi_sandbox_hanami/.rspec +0 -1
  238. data/sandbox/itsi_sandbox_hanami/Gemfile +0 -49
  239. data/sandbox/itsi_sandbox_hanami/Gemfile.lock +0 -440
  240. data/sandbox/itsi_sandbox_hanami/Guardfile +0 -9
  241. data/sandbox/itsi_sandbox_hanami/Procfile.dev +0 -2
  242. data/sandbox/itsi_sandbox_hanami/README.md +0 -1
  243. data/sandbox/itsi_sandbox_hanami/Rakefile +0 -3
  244. data/sandbox/itsi_sandbox_hanami/app/action.rb +0 -12
  245. data/sandbox/itsi_sandbox_hanami/app/actions/.keep +0 -0
  246. data/sandbox/itsi_sandbox_hanami/app/assets/css/app.css +0 -5
  247. data/sandbox/itsi_sandbox_hanami/app/assets/images/favicon.ico +0 -0
  248. data/sandbox/itsi_sandbox_hanami/app/assets/js/app.js +0 -1
  249. data/sandbox/itsi_sandbox_hanami/app/db/relation.rb +0 -10
  250. data/sandbox/itsi_sandbox_hanami/app/db/repo.rb +0 -10
  251. data/sandbox/itsi_sandbox_hanami/app/db/struct.rb +0 -10
  252. data/sandbox/itsi_sandbox_hanami/app/operation.rb +0 -9
  253. data/sandbox/itsi_sandbox_hanami/app/relations/.keep +0 -0
  254. data/sandbox/itsi_sandbox_hanami/app/repos/.keep +0 -0
  255. data/sandbox/itsi_sandbox_hanami/app/structs/.keep +0 -0
  256. data/sandbox/itsi_sandbox_hanami/app/templates/layouts/app.html.erb +0 -14
  257. data/sandbox/itsi_sandbox_hanami/app/view.rb +0 -9
  258. data/sandbox/itsi_sandbox_hanami/app/views/helpers.rb +0 -10
  259. data/sandbox/itsi_sandbox_hanami/bin/dev +0 -8
  260. data/sandbox/itsi_sandbox_hanami/config/app.rb +0 -8
  261. data/sandbox/itsi_sandbox_hanami/config/assets.js +0 -16
  262. data/sandbox/itsi_sandbox_hanami/config/db/migrate/.keep +0 -0
  263. data/sandbox/itsi_sandbox_hanami/config/db/seeds.rb +0 -15
  264. data/sandbox/itsi_sandbox_hanami/config/puma.rb +0 -47
  265. data/sandbox/itsi_sandbox_hanami/config/routes.rb +0 -7
  266. data/sandbox/itsi_sandbox_hanami/config/settings.rb +0 -9
  267. data/sandbox/itsi_sandbox_hanami/config.ru +0 -5
  268. data/sandbox/itsi_sandbox_hanami/db/.keep +0 -0
  269. data/sandbox/itsi_sandbox_hanami/lib/itsi_hanami/types.rb +0 -11
  270. data/sandbox/itsi_sandbox_hanami/lib/tasks/.keep +0 -0
  271. data/sandbox/itsi_sandbox_hanami/package-lock.json +0 -946
  272. data/sandbox/itsi_sandbox_hanami/package.json +0 -8
  273. data/sandbox/itsi_sandbox_hanami/spec/requests/root_spec.rb +0 -11
  274. data/sandbox/itsi_sandbox_hanami/spec/spec_helper.rb +0 -9
  275. data/sandbox/itsi_sandbox_hanami/spec/support/db/cleaning.rb +0 -42
  276. data/sandbox/itsi_sandbox_hanami/spec/support/db.rb +0 -10
  277. data/sandbox/itsi_sandbox_hanami/spec/support/features.rb +0 -5
  278. data/sandbox/itsi_sandbox_hanami/spec/support/operations.rb +0 -8
  279. data/sandbox/itsi_sandbox_hanami/spec/support/requests.rb +0 -13
  280. data/sandbox/itsi_sandbox_hanami/spec/support/rspec.rb +0 -61
  281. data/sandbox/itsi_sandbox_rack/Gemfile +0 -17
  282. data/sandbox/itsi_sandbox_rack/Gemfile.lock +0 -153
  283. data/sandbox/itsi_sandbox_rack/config.ru +0 -5
  284. data/sandbox/itsi_sandbox_rack_lint/Gemfile +0 -7
  285. data/sandbox/itsi_sandbox_rack_lint/Gemfile.lock +0 -27
  286. data/sandbox/itsi_sandbox_rack_lint/config.ru +0 -3
  287. data/sandbox/itsi_sandbox_rails/.dockerignore +0 -48
  288. data/sandbox/itsi_sandbox_rails/.gitattributes +0 -9
  289. data/sandbox/itsi_sandbox_rails/.github/dependabot.yml +0 -12
  290. data/sandbox/itsi_sandbox_rails/.github/workflows/ci.yml +0 -90
  291. data/sandbox/itsi_sandbox_rails/.gitignore +0 -35
  292. data/sandbox/itsi_sandbox_rails/.rubocop.yml +0 -8
  293. data/sandbox/itsi_sandbox_rails/.ruby-version +0 -1
  294. data/sandbox/itsi_sandbox_rails/Dockerfile +0 -69
  295. data/sandbox/itsi_sandbox_rails/Gemfile +0 -66
  296. data/sandbox/itsi_sandbox_rails/Gemfile.lock +0 -429
  297. data/sandbox/itsi_sandbox_rails/README.md +0 -24
  298. data/sandbox/itsi_sandbox_rails/Rakefile +0 -6
  299. data/sandbox/itsi_sandbox_rails/app/assets/config/manifest.js +0 -4
  300. data/sandbox/itsi_sandbox_rails/app/assets/images/.keep +0 -0
  301. data/sandbox/itsi_sandbox_rails/app/assets/stylesheets/application.css +0 -15
  302. data/sandbox/itsi_sandbox_rails/app/channels/application_cable/channel.rb +0 -4
  303. data/sandbox/itsi_sandbox_rails/app/channels/application_cable/connection.rb +0 -4
  304. data/sandbox/itsi_sandbox_rails/app/controllers/application_controller.rb +0 -4
  305. data/sandbox/itsi_sandbox_rails/app/controllers/concerns/.keep +0 -0
  306. data/sandbox/itsi_sandbox_rails/app/controllers/home_controller.rb +0 -66
  307. data/sandbox/itsi_sandbox_rails/app/controllers/live_controller.rb +0 -40
  308. data/sandbox/itsi_sandbox_rails/app/controllers/uploads_controller.rb +0 -29
  309. data/sandbox/itsi_sandbox_rails/app/helpers/application_helper.rb +0 -2
  310. data/sandbox/itsi_sandbox_rails/app/javascript/application.js +0 -3
  311. data/sandbox/itsi_sandbox_rails/app/javascript/controllers/application.js +0 -9
  312. data/sandbox/itsi_sandbox_rails/app/javascript/controllers/hello_controller.js +0 -7
  313. data/sandbox/itsi_sandbox_rails/app/javascript/controllers/index.js +0 -4
  314. data/sandbox/itsi_sandbox_rails/app/jobs/application_job.rb +0 -7
  315. data/sandbox/itsi_sandbox_rails/app/mailers/application_mailer.rb +0 -4
  316. data/sandbox/itsi_sandbox_rails/app/models/application_record.rb +0 -3
  317. data/sandbox/itsi_sandbox_rails/app/models/concerns/.keep +0 -0
  318. data/sandbox/itsi_sandbox_rails/app/models/post.rb +0 -2
  319. data/sandbox/itsi_sandbox_rails/app/views/layouts/application.html.erb +0 -23
  320. data/sandbox/itsi_sandbox_rails/app/views/layouts/mailer.html.erb +0 -13
  321. data/sandbox/itsi_sandbox_rails/app/views/layouts/mailer.text.erb +0 -1
  322. data/sandbox/itsi_sandbox_rails/app/views/pwa/manifest.json.erb +0 -22
  323. data/sandbox/itsi_sandbox_rails/app/views/pwa/service-worker.js +0 -26
  324. data/sandbox/itsi_sandbox_rails/bin/brakeman +0 -7
  325. data/sandbox/itsi_sandbox_rails/bin/bundle +0 -109
  326. data/sandbox/itsi_sandbox_rails/bin/docker-entrypoint +0 -13
  327. data/sandbox/itsi_sandbox_rails/bin/importmap +0 -4
  328. data/sandbox/itsi_sandbox_rails/bin/rails +0 -4
  329. data/sandbox/itsi_sandbox_rails/bin/rake +0 -4
  330. data/sandbox/itsi_sandbox_rails/bin/rubocop +0 -8
  331. data/sandbox/itsi_sandbox_rails/bin/setup +0 -37
  332. data/sandbox/itsi_sandbox_rails/config/application.rb +0 -27
  333. data/sandbox/itsi_sandbox_rails/config/boot.rb +0 -4
  334. data/sandbox/itsi_sandbox_rails/config/cable.yml +0 -10
  335. data/sandbox/itsi_sandbox_rails/config/credentials.yml.enc +0 -1
  336. data/sandbox/itsi_sandbox_rails/config/database.yml +0 -30
  337. data/sandbox/itsi_sandbox_rails/config/environment.rb +0 -5
  338. data/sandbox/itsi_sandbox_rails/config/environments/development.rb +0 -82
  339. data/sandbox/itsi_sandbox_rails/config/environments/production.rb +0 -106
  340. data/sandbox/itsi_sandbox_rails/config/environments/test.rb +0 -67
  341. data/sandbox/itsi_sandbox_rails/config/importmap.rb +0 -7
  342. data/sandbox/itsi_sandbox_rails/config/initializers/assets.rb +0 -12
  343. data/sandbox/itsi_sandbox_rails/config/initializers/content_security_policy.rb +0 -25
  344. data/sandbox/itsi_sandbox_rails/config/initializers/filter_parameter_logging.rb +0 -8
  345. data/sandbox/itsi_sandbox_rails/config/initializers/inflections.rb +0 -16
  346. data/sandbox/itsi_sandbox_rails/config/initializers/permissions_policy.rb +0 -13
  347. data/sandbox/itsi_sandbox_rails/config/locales/en.yml +0 -31
  348. data/sandbox/itsi_sandbox_rails/config/puma.rb +0 -34
  349. data/sandbox/itsi_sandbox_rails/config/routes.rb +0 -23
  350. data/sandbox/itsi_sandbox_rails/config/storage.yml +0 -34
  351. data/sandbox/itsi_sandbox_rails/config.ru +0 -6
  352. data/sandbox/itsi_sandbox_rails/db/migrate/20250301041554_create_posts.rb +0 -10
  353. data/sandbox/itsi_sandbox_rails/db/schema.rb +0 -23
  354. data/sandbox/itsi_sandbox_rails/db/seeds.rb +0 -9
  355. data/sandbox/itsi_sandbox_rails/lib/assets/.keep +0 -0
  356. data/sandbox/itsi_sandbox_rails/lib/tasks/.keep +0 -0
  357. data/sandbox/itsi_sandbox_rails/log/.keep +0 -0
  358. data/sandbox/itsi_sandbox_rails/public/404.html +0 -67
  359. data/sandbox/itsi_sandbox_rails/public/406-unsupported-browser.html +0 -66
  360. data/sandbox/itsi_sandbox_rails/public/422.html +0 -67
  361. data/sandbox/itsi_sandbox_rails/public/500.html +0 -66
  362. data/sandbox/itsi_sandbox_rails/public/icon.png +0 -0
  363. data/sandbox/itsi_sandbox_rails/public/icon.svg +0 -3
  364. data/sandbox/itsi_sandbox_rails/public/robots.txt +0 -1
  365. data/sandbox/itsi_sandbox_rails/storage/.keep +0 -0
  366. data/sandbox/itsi_sandbox_rails/test/application_system_test_case.rb +0 -5
  367. data/sandbox/itsi_sandbox_rails/test/channels/application_cable/connection_test.rb +0 -13
  368. data/sandbox/itsi_sandbox_rails/test/controllers/.keep +0 -0
  369. data/sandbox/itsi_sandbox_rails/test/fixtures/files/.keep +0 -0
  370. data/sandbox/itsi_sandbox_rails/test/helpers/.keep +0 -0
  371. data/sandbox/itsi_sandbox_rails/test/integration/.keep +0 -0
  372. data/sandbox/itsi_sandbox_rails/test/mailers/.keep +0 -0
  373. data/sandbox/itsi_sandbox_rails/test/models/.keep +0 -0
  374. data/sandbox/itsi_sandbox_rails/test/system/.keep +0 -0
  375. data/sandbox/itsi_sandbox_rails/test/test_helper.rb +0 -15
  376. data/sandbox/itsi_sandbox_rails/tmp/.keep +0 -0
  377. data/sandbox/itsi_sandbox_rails/tmp/pids/.keep +0 -0
  378. data/sandbox/itsi_sandbox_rails/tmp/storage/.keep +0 -0
  379. data/sandbox/itsi_sandbox_rails/vendor/.keep +0 -0
  380. data/sandbox/itsi_sandbox_rails/vendor/javascript/.keep +0 -0
  381. data/sandbox/itsi_sandbox_roda/Gemfile +0 -5
  382. data/sandbox/itsi_sandbox_roda/Gemfile.lock +0 -37
  383. data/sandbox/itsi_sandbox_roda/config.ru +0 -39
  384. data/sandbox/itsi_sinatra/Gemfile +0 -9
  385. data/sandbox/itsi_sinatra/Gemfile.lock +0 -81
  386. data/sandbox/itsi_sinatra/app.rb +0 -8
  387. data/sandbox/pebble/docker-compose.yml +0 -11
  388. data/sandbox/static_files/.env +0 -1
  389. data/sandbox/static_files/404.html +0 -25
  390. data/sandbox/static_files/_DSC0102.NEF.jpg +0 -0
  391. data/sandbox/static_files/about.html +0 -68
  392. data/sandbox/static_files/tiny.html +0 -1
  393. data/sandbox/static_files/writebook.zip +0 -0
@@ -0,0 +1,285 @@
1
+ ---
2
+ title: Features
3
+ type: docs
4
+ weight: 1
5
+ ---
6
+
7
+ Itsi bundles a slew of essential modern web features into a single, easy-to-use package.
8
+ Here's a list of several of the essentials.
9
+ Jump straight in to [install Itsi](/getting_started) and [configure it](/configuration) for a deeper dive.
10
+
11
+ {{< callout >}}
12
+ You don't need to use all of the features listed below to benefit from Itsi. E.g.
13
+ * Use it *just* as fast, robust and memory efficient Rack server.
14
+ * Or as a reverse proxy that allows you to use plain-old Ruby for configuration.
15
+
16
+ Pick and choose **just** the features that make sense for you.
17
+
18
+ {{< /callout >}}
19
+
20
+
21
+ ## Web Essentials
22
+ {{% details title="Compression" closed="true" %}}
23
+ * `zstd`, `br`, `gzip` and `deflate` compression.
24
+ * Conditional compression based on route, content-type and body size
25
+ * Streaming compression
26
+ * Serve static precompressed files from the file-system
27
+ * gRPC compression (`zlib` and `gzip`)
28
+ * See [compression](/middleware/compression)
29
+ {{% /details %}}
30
+
31
+ {{% details title="CORS" closed="true" %}}
32
+ * Full control over CORS rules on a location-by-location basis.
33
+ * See [cors](/middleware/cors)
34
+ {{% /details %}}
35
+
36
+ {{% details title="ETag and Cache Control" closed="true" %}}
37
+ * Weak and Strong eTag support.
38
+ * `If-None-Match` and `If-Modified-Since` support.
39
+ * Automated etag generation for dynamic content (or forwarding of existing `etags` if present)
40
+ * See [etag](/middleware/etag)
41
+ {{% /details %}}
42
+
43
+ {{% details title="Conditional Middleware" closed="true" %}}
44
+ * Expressive controls to apply middleware selectively on a request-by-request basis.
45
+ * Expressive matching based on route, content-type and body size, hostnames etc.
46
+ * A single Itsi process can support simultaneous running of several apps, each with specialized configuration.
47
+ * See [location](/middleware/location)
48
+ {{% /details %}}
49
+
50
+ {{% details title="Redirects" closed="true" %}}
51
+ * Simple redirect functionality (all of `permanent`, `temporary`, `found`, `moved_permanently`)
52
+ * HTTP to HTTPs Redirects
53
+ * Dynamic URL Rewriting
54
+ * See [redirect](/middleware/redirect)
55
+ {{% /details %}}
56
+
57
+ {{% details title="Reverse Proxy" closed="true" %}}
58
+ * Seamlessly Proxy to downstream HTTP services
59
+ * Hostname and SNI overrides
60
+ * Header overrides
61
+ * Multiple backends per host, with load balancing and failover support
62
+ * Automatic retries for Idempotent requests
63
+ * Configurable error pages
64
+ * See [proxy](/middleware/proxy)
65
+ {{% /details %}}
66
+
67
+ {{% details title="Range Requests" closed="true" %}}
68
+ * Partial content delivery support, so clients can resume downloads or stream large files efficiently.
69
+ * See [static_assets](/middleware/static_assets)
70
+ {{% /details %}}
71
+
72
+ {{% details title="Static File Server" closed="true" %}}
73
+ Efficiently serves static assets with proper content types and caching headers.
74
+ * Auto index generation
75
+ * Configurable in-memory caching for faster serving of small and frequently accessed files.
76
+ * Auto try `.html` extension (for cleaner paths)
77
+ * Configurable fallback behaviour (e.g. route request misses to an index.html for SPAs)
78
+ * See [static_assets](/middleware/static_assets)
79
+ {{% /details %}}
80
+
81
+ {{% details title="Multiple Binds" closed="true" %}}
82
+ * Itsi can listen on multiple IP addresses or ports simultaneously for flexible deployment.
83
+ * Unix socket binds (both plain-text and TLS) are supported.
84
+ * See [bind](/options/bind).
85
+ {{% /details %}}
86
+
87
+ ## DevOps
88
+ {{% details title="File Watcher & Live Reloading" closed="true" %}}
89
+ * Monitors file changes and to automatically reloads configuration or content.
90
+ * Use custom watchers to e.g. trigger frontend builds on file changes.
91
+ * See [local_development](/getting_started/local_development).
92
+ {{% /details %}}
93
+
94
+ {{% details title="LSP and shell completion support" closed="true" %}}
95
+ * The bundled RubyLSP addon provides rich inline documentation and hover support when editing `Itsi.rb` files.
96
+ * Shell completion support (just add `eval "$(itsi --install-completions)"` to the bottom of your shell init file)
97
+ * See [local_development](/getting_started/local_development).
98
+ {{% /details %}}
99
+
100
+ {{% details title="Status Reporting" closed="true" %}}
101
+ * Send SIGUSR2 to trigger detailed status report across all Itsi processes.
102
+ * See [signals](/getting_started/signals).
103
+ {{% /details %}}
104
+
105
+ {{% details title="Granular Logging" closed="true" %}}
106
+ * Support logging using plain-text and structured `JSON` formats.
107
+ * Support `STDOUT`, file-system and combined log sinks.
108
+ * Apply selective log levels for specific log targets only.
109
+ * Configurable request logging middleware, with custom log templates.
110
+ * See [log_responses](/middleware/log_responses) & [logging](/getting_started/logging).
111
+ {{% /details %}}
112
+
113
+ {{% details title="Hot Config Reloads & Config File Validation" closed="true" %}}
114
+ * Zero-downtime config file reloads.
115
+ * Phased restart support when running in `cluster` mode
116
+ * Config file testing and dry-run functionality
117
+ * See [hot_reloads](/getting_started/hot_reloads).
118
+ {{% /details %}}
119
+
120
+ {{% details title="Configurable Error Responses" closed="true" %}}
121
+ * Provide your own exception responses (HTML and JSON) for all common exception scenarios, or simply rely on the light-weight defaults.
122
+ * See [error_responses](/middleware/error_responses).
123
+ {{% /details %}}
124
+
125
+ {{% details title="Management Signals" closed="true" %}}
126
+ * Use a full suite of Unix signals to control your live Itsi cluster.
127
+ * Add or remove workers on the fly, reload config, generate status reports etc.
128
+ * See [signals](/getting_started/signals).
129
+ {{% /details %}}
130
+
131
+ ## Security
132
+ {{% details title="JWT/API Key/Basic Auth" closed="true" %}}
133
+ * Apply common authentication patterns at the middleware layer.
134
+ * API Key (`bcrypt`, `argon2`, `sha256`, `sha512`)
135
+ * JWT (`hs256`, `HS384`, `HS512`, `RS256`, `RS384`, `RS512`, `ES256`, `ES384`, `PS256`, `PS384`, `PS512`)
136
+ * Basic Auth (`bcrypt`, `argon2`, `sha256`, `sha512`)
137
+
138
+ Itsi also comes bundled with a passfile generator, to help you manage your password hashes effectively.
139
+
140
+ * See [auth_jwt](/middleware/auth_jwt), [auth_api_key](/middleware/auth_api_key), [auth_basic](/middleware/auth_basic) and [passfile](/getting_started/passfile).
141
+ {{% /details %}}
142
+
143
+ {{% details title="Automatic Let's Encrypt Certificates" closed="true" %}}
144
+ * Automated provisioning of Let's Encrypt certificates.
145
+ * File system caching of certificate data to avoid excessive API calls.
146
+ * Supports usage of subject alternative names (SANs) for certificates that span multiple domains/sub-domains.
147
+ * See [bind](/options/bind).
148
+ {{% /details %}}
149
+
150
+ {{% details title="Automatic Development Certificates" closed="true" %}}
151
+ * Easily mirror your production SSL set-up in Development
152
+ * Custom local CA generation (add this CA cert to your trusted root certificates for warning-less SSL during local development)
153
+ * See [bind](/options/bind).
154
+ {{% /details %}}
155
+
156
+ {{% details title="(Distributed) Rate Limiting" closed="true" %}}
157
+ * Combine any number of configurable rate limits
158
+ * Support for a `Redis` backend for distributed rate limiting (falls back to in-memory backend)
159
+ * In-memory backend for simple setups and local development.
160
+ * See [rate_limit](/middleware/rate_limit).
161
+ {{% /details %}}
162
+
163
+ {{% details title="Allow & Deny Lists" closed="true" %}}
164
+ * IP Allow lists to limit access to a specific set of IP addresses or blocks.
165
+ * IP Deny lists to block access from specific IP addresses or blocks.
166
+ * See [allow_list](/middleware/allow_list) & [deny_list](/middleware/deny_list).
167
+ {{% /details %}}
168
+
169
+ {{% details title="Intrusion Protection" closed="true" %}}
170
+ * Automatically scan request paths and headers for known malicious patterns
171
+ * Configurable ban rules to block offenders for a specified duration.
172
+ * See [intrusion_protection](/middleware/intrusion_protection)
173
+ {{% /details %}}
174
+
175
+ {{% details title="Slowhttp attack prevention" closed="true" %}}
176
+ * Protections against several slowhttp attacks (e.g. Slowloris, Slowbody), through header and request timeouts and maximum request body sizes.
177
+ * See [max_body](/options/max_body), [request_timeout](/options/request_timeout) and [header_read_timeout](/options/header_read_timeout)
178
+ {{% /details %}}
179
+
180
+ {{% details title="CSP Reporting" closed="true" %}}
181
+ * Simple configuration for enabling CSP headers.
182
+ * Support for hosting a CSP reporting endpoint to track violations of CSPs running in reporting only mode.
183
+ * See [CSP](/middleware/csp)
184
+ {{% /details %}}
185
+
186
+ ## Protocols & Standards
187
+ {{% details title="HTTP2" closed="true" %}}
188
+ * Benefit from connection multiplexing by using http2 all the way from client to app/file server.
189
+ * `Itsi`'s underlying HTTP1 and 2 implementations are provided directly by [hyper](https://github.com/hyperium/hyper). Itsi simply exposes these existing capabilities. This means that once [h3](https://hyper.rs/contrib/roadmap/#http3) lands in Hyper - we'll get it in Itsi too!
190
+ {{% /details %}}
191
+
192
+ {{% details title="Rack Server" closed="true" %}}
193
+ * Rack compliant. Itsi plays nicely with your existing Rack-based applications and middleware.
194
+ * See [run](/middleware/run) and [rack_file](/middleware/rack_file)
195
+ {{% /details %}}
196
+
197
+ {{% details title="gRPC Server" closed="true" %}}
198
+ * Itsi is compatible with ruby `grpc` service handlers and can
199
+ replace the [official Ruby gRPC server implementation](https://github.com/grpc/grpc/blob/master/src/ruby/README.md) for a free performance boost!
200
+ * Consider implementing non-blocking IO to further enhance performance.
201
+ * Support for gRPC server reflection (use with tools like evans and Postman for easy service discovery)
202
+ * Support for gzip and zlib compression
203
+ * See [grpc](/middleware/grpc)
204
+ {{% /details %}}
205
+
206
+ {{% details title="gRPC+REST compatibility mode" closed="true" %}}
207
+ * Itsi provides a `gRPC+REST` compatibility layer for easy reuse of gRPC endpoints by clients and environments that are not gRPC capable. Invoke unidirectional and streaming endpoints using plain-old JSON.
208
+ * See [grpc](/middleware/grpc)
209
+ {{< callout type="warn" >}}
210
+ Note: This is not the same as [gRPC with Json](https://grpc.io/blog/grpc-with-json/), which swaps out protobuf for JSON but still relies on gRPC's underlying framing mechanics.
211
+ {{< /callout >}}
212
+ {{% /details %}}
213
+
214
+ {{% details title="WebSockets" closed="true" %}}
215
+ * WebSocket support for Rack apps (e.g. [ActionCable](https://guides.rubyonrails.org/action_cable_overview.html))
216
+ {{% /details %}}
217
+
218
+ ## Concurrency & Performance
219
+ {{% details title="Cluster Mode" closed="true" %}}
220
+ * Supports running in a clustered mode, to fully leverage multi-core systems.
221
+ * See [workers](/options/workers).
222
+ {{% /details %}}
223
+
224
+ {{% details title="Non-blocking(Fiber Scheduler) Mode" closed="true" %}}
225
+ * Support for Ruby’s fiber scheduler for non-blocking concurrency, boosting performance during I/O operations.
226
+ * Use Itsi's own high-performance build-in [Fiber scheduler](/itsi_scheduler), or if your prefer you can bring your own!
227
+ * See [fiber_scheduler](/options/fiber_scheduler).
228
+ {{% /details %}}
229
+
230
+ {{% details title="Hybrid Blocking/Non-Blocking Mode" closed="true" %}}
231
+ * `Itsi` allows you to split endpoints between using a Fiber scheduler versus running using the traditional blocking IO model. This allows you to dip your toes into the waters of Ruby's new non-blocking IO, without having to port an entire application at once!
232
+ * See [scheduler_threads](/options/scheduler_threads).
233
+ {{% /details %}}
234
+
235
+ {{% details title="Non-blocking by design" closed="true" %}}
236
+ * Itsi is underpinned by [hyper](https://hyper.rs/) and [tokio](https://tokio.rs/) and as such is fundamentally an evented, non-blocking server. Whether you're proxying, serving large files, or delegating to Ruby endpoints, `Itsi` remains responsive, even under heavy load.
237
+ {{% /details %}}
238
+
239
+ ## Ruby
240
+ {{% details title="Preloading" closed="true" %}}
241
+ * Preload your Ruby application code before forking to benefit from reduced memory through CoW
242
+ * Alternatively, use groups in bundler to target specific gems or dependencies for preloading
243
+ * See [preload](/options/preload).
244
+ {{% /details %}}
245
+
246
+ {{% details title="Streaming Bodies" closed="true" %}}
247
+ * For both [streaming and enumerable bodies](https://github.com/rack/rack/blob/main/SPEC.rdoc#the-body-), Itsi sends data to the client as soon as it is available. This means modules like [ActionController::Live](https://api.rubyonrails.org/v7.1/classes/ActionController/Live.html) behave as expected, and the minimal buffering keeps `Itsi`'s memory footprint consistently low.
248
+ {{% /details %}}
249
+
250
+ {{% details title="Full & Partial Rack Hijacking" closed="true" %}}
251
+ * Itsi supports both [full and partial Rack hijacking](https://github.com/rack/rack/blob/main/SPEC.rdoc#hijacking-). Even over HTTP2!
252
+ {{< callout type="warn" >}}
253
+ By design, Full hijacking assumes you are writing a raw HTTP1 response directly to a raw connection stream.
254
+ Itsi's support for full hijack over HTTP2 is similar to what you would see if running a dedicated reverse proxy in front of a Ruby app.
255
+ Itsi translates that request from HTTP1 to HTTP2, in real-time, allowing full hijacking endpoints to write HTTP1 and the client to receive HTTP2.
256
+ {{< /callout >}}
257
+ {{% /details %}}
258
+
259
+ {{% details title="Sendfile" closed="true" %}}
260
+ * Itsi allows Ruby apps to set a `X-Sendfile` header to enable efficient, streaming file transfers, outside of Ruby, via fast native code.
261
+ * See [run](/middleware/run) and [rack_file](/middleware/rack_file).
262
+
263
+ {{< callout type="info" >}}
264
+ Note that despite the header being named `X-Sendfile`, Itsi does not use the Sendfile system call, instead delegating the efficient streaming to Tokio's native asynchronous file streaming capabilities.
265
+ {{< /callout >}}
266
+
267
+ {{% /details %}}
268
+
269
+ {{% details title="Graceful Memory Limits" closed="true" %}}
270
+ * Itsi allows you to specify memory limits for Ruby processes. When the limit is reached, Itsi gracefully terminates the process and also invokes a dedicated `after_memory_threshold_reached` callback,
271
+ so that you can log the event for further analysis.
272
+ * See [worker_memory_limit](/options/worker_memory_limit) and [after_memory_threshold_reached](/options/after_memory_threshold_reached).
273
+ {{% /details %}}
274
+
275
+ {{% details title="OOB GC" closed="true" %}}
276
+ * Itsi can be configured to periodically trigger GC every N idle periods (where an idle period is defined as a time where no requests are currently queued).
277
+ * Periodic triggering of GC outside of the request flow can help reduce the impact of GC on latency.
278
+ * See [oob_gc_threshold](/options/oob_gc_threshold)
279
+ {{% /details %}}
280
+
281
+ {{% details title="'Rackless' Ruby Apps" closed="true" %}}
282
+ * Itsi allows definition of ultra-light-weight Ruby web-apps, using plain old functions and procs.
283
+ * For simple endpoints this barebones option can provide a substantial increase in throughput over a Rack request (primarily by avoiding allocating the env hash and response array)
284
+ * See [endpoint](/middleware/endpoint)
285
+ {{% /details %}}
@@ -0,0 +1,70 @@
1
+ ---
2
+ title: Getting Started
3
+ type: docs
4
+ weight: 2
5
+ ---
6
+
7
+ {{% steps %}}
8
+
9
+ ### Step 1 - Install Ruby
10
+
11
+ Install Ruby
12
+
13
+ [https://www.ruby-lang.org/en/documentation/installation/](https://www.ruby-lang.org/en/documentation/installation/)
14
+
15
+ ### Step 2 - Install Itsi
16
+
17
+ {{< tabs items="Linux,Mac,Windows" >}}
18
+ {{< tab >}}
19
+ **Prerequisites**
20
+
21
+ You'll need at least `build-essential` and `libclang-dev` installed to build Itsi on Linux.
22
+ E.g.
23
+ ```bash
24
+ apt-get install build-essential libclang-dev
25
+ ```
26
+
27
+ Then use `gem` to install the Itsi package. This will in turn install both the
28
+ `itsi-server` gem, and the `itsi-scheduler` gem.
29
+
30
+
31
+ ```bash
32
+ gem install itsi
33
+ ```
34
+
35
+ {{< callout type="info" >}}
36
+ If you wish to use either the scheduler or server independently, these can be installed individually
37
+ by running `gem install itsi-server` or `gem install itsi-scheduler`.
38
+ {{< /callout >}}
39
+
40
+ {{< /tab >}}
41
+ {{< tab >}}
42
+ **Mac**:
43
+ ```bash
44
+ gem install itsi
45
+ ```
46
+ {{< callout type="info" >}}
47
+ If you wish to use either the scheduler or server independently, these can be installed individually
48
+ by running `gem install itsi-server` or `gem install itsi-scheduler`.
49
+ {{< /callout >}}
50
+
51
+ {{< /tab >}}
52
+ {{< tab >}}**Windows**: Itsi currently doesn't support native Windows builds, but it runs great on [https://learn.microsoft.com/en-us/windows/wsl/install](WSL).
53
+
54
+ Follow the linked instructions to Install a linux distribution like Ubuntu or Debian and then follow the instructions in the Linux tab.
55
+ {{< /tab >}}
56
+
57
+ {{< /tabs >}}
58
+
59
+ ### Step 3 - Learn More
60
+
61
+ Great! You now have Itsi installed. Go to one of the following pages to learn how to use it:
62
+
63
+ {{< cards >}}
64
+ {{< card link="../features" title="Essential Features" icon="star" >}}
65
+ {{< card link="../configuration" title="Configuration" icon="adjustments" >}}
66
+ {{< card link="../reverse_proxy" title="Reverse Proxy & Gateway" icon="arrow-circle-right" >}}
67
+ {{< card link="../for_rubyists" title="For Ruby Apps" icon="library" >}}
68
+ {{< /cards >}}
69
+
70
+ {{% /steps %}}
@@ -0,0 +1,40 @@
1
+ ---
2
+ title: Local Development
3
+ type: docs
4
+ weight: 3
5
+ ---
6
+
7
+ {{< callout>}}
8
+ Itsi provides several optional niceties to enhance your local development experience.
9
+ This document is non-essential reading, but worth covering if you're trying Itsi in earnest and want a substantially better
10
+ local development experience!
11
+ {{< /callout >}}
12
+
13
+ ## Ruby LSP Add-on
14
+ Itsi's [RubyLSP](https://shopify.github.io/ruby-lsp/) add-on allows you to see the full documentation of all of Itsi's [`options`](/options) and [`middleware`](/middleware) directly
15
+ inside your editor. It also gives you easy to use auto-completion and snippets for lightning fast changes to `Itsi.rb` configuration files.
16
+ You don't need to install the RubyLSP add-on to use Itsi, if both Itsi and RubyLSP are installed and activated in the same project, RubyLSP will automatically
17
+ discover and load the addon.
18
+
19
+ <img src="/ruby-lsp.png" alt="asd" width="700px" style="display: block; margin-left: auto; margin-right: auto;">
20
+
21
+ ## Live Config Reloading
22
+ Just add `auto_reload_config!` to your `Itsi.rb` configuration file and Itsi will automatically hot reload its config with every change you make.
23
+ Concerned about errors? Itsi will validate your config first before it tries to apply it. If there are errors, Itsi will provide details logs and safely continue with the existing config.
24
+
25
+ ### File Watcher
26
+ You can have Itsi watch other files on the file-system and trigger automatic actions in response.
27
+ Use the `watch(glob, commands)` method to specify files or directories to watch, and command to execute with each change.
28
+ E.g.
29
+ ```ruby
30
+ watch "**.js", [%w[npm run build]]
31
+ watch "**.md", [%w[rake docs:build]]
32
+ ```
33
+
34
+ ## Shell Completions
35
+ Itsi can also help you install shell completions, which are useful if you find yourself using the `itsi` executable a lot and forgetting the commands.
36
+ Just add the bottom to your `~/.bashrc` or `~/.zshrc` file:
37
+
38
+ ```bash
39
+ eval "$(itsi --install-completions)"
40
+ ```
@@ -0,0 +1,16 @@
1
+ ---
2
+ title: Logging
3
+ type: docs
4
+ weight: 4
5
+ ---
6
+
7
+ ## Targeted Logging
8
+ * Having trouble configuring a specific middleware layer, but debug logs are too verbose? You can change the log-level for a specific middleware layer,
9
+ while leaving all other layers at the current global level.
10
+ E.g.
11
+
12
+ ```bash
13
+ # auth_api_key middleware will log debug messages
14
+ # everything else will stick to the INFO level.
15
+ ITSI_LOG=info,auth_api_key=debug itsi
16
+ ```
@@ -0,0 +1,24 @@
1
+ ---
2
+ title: Running Itsi in Production
3
+ type: docs
4
+ weight: 3
5
+ next: /configuration
6
+ ---
7
+
8
+ ## Docker
9
+ Itsi runs well within any Dockerfile that has support for `Ruby 2.7+` and is able to build the Rust toolchain.
10
+ You can try Itsi in a Docker container using the official Itsi Docker image
11
+ ```bash
12
+ docker run -it --rm wouterken/itsi:latest
13
+ ```
14
+
15
+ See the source of this Dockerfile inside the [Github repository](https://github.com/wouterken/itsi/blob/main/Dockerfile).
16
+
17
+ ## Signal Handling
18
+ Itsi supports common signals such as SIGINT and SIGTERM for graceful termination by deployment scripts or container orchestration systems like
19
+ K8s and Docker swarm.
20
+
21
+ {{< callout type="warn" >}}
22
+ If you're planning to use Itsi for a high throughput application in K8s, read [this article](https://github.com/puma/puma/blob/master/docs/kubernetes.md) about running
23
+ Puma in Kubernetes. The same advice applies to Itsi.
24
+ {{< /callout >}}
Binary file
@@ -0,0 +1,105 @@
1
+ ---
2
+ title: Itsi Scheduler
3
+ type: docs
4
+ weight: 4
5
+ sidebar:
6
+ exclude: true
7
+ ---
8
+ <img src="itsi-scheduler-100.png" width="80px" style="display: block; margin-left: auto; margin-right: auto;">
9
+
10
+ `Itsi Scheduler` is an implementation of a Ruby [Fiber Scheduler](https://docs.ruby-lang.org/en/3.2/Fiber/Scheduler.html).
11
+
12
+ When combined with Itsi Server, you can write endpoints that look and feel exactly like regular synchronous Ruby code,
13
+ but behind the scenes, the scheduler will transparently yield and resume concurrent request fibers, to prevent threads from blocking and greatly increase throughput for IO heavy workloads.
14
+
15
+ If you're purely after a light-weight, yet efficient Ruby scheduler,
16
+ you can use Itsi Scheduler as a standalone scheduler for any Ruby application.
17
+
18
+ Just use `Fiber.set_scheduler` to set an instance `Itsi::Scheduler` as a scheduler to opt in to this IO weaving behaviour
19
+ *automatically* for all blocking IO.
20
+
21
+ ### Primer on Fiber Schedulers
22
+
23
+ Fiber schedulers are a way to automatically manage the execution of non-blocking fibers in Ruby. A scheduler is responsible for the automatic pausing and resumption of Fibers based
24
+ on whether or not they are awaiting IO operations.
25
+ Ruby's Fiber scheduler implementation automatically invokes the current Fiber scheduler (if it exists) for each blocking operation, allowing it to seamlessly drive the execution of huge numbers of simultaneous non-blocking fibers
26
+ while ensuring the main thread is never blocked on IO.
27
+
28
+ This behind the scenes magic allows Ruby to provide async IO (just like we find in languages with `async/await` like `Rust`, `C#`, `JavaScript`) *but* with the added beauty
29
+ that synchronous and asynchronous code is identical! (I.e. Ruby's functions are [colorless](https://journal.stuffwithstuff.com/2015/02/01/what-color-is-your-function/))
30
+
31
+ ## Getting Started
32
+ To install and use Itsi Scheduler follow the below instructions:
33
+
34
+ {{% steps %}}
35
+
36
+
37
+ ### 1 - Install Itsi Scheduler
38
+
39
+ {{< tabs items="Linux,Mac,Windows" >}}
40
+ {{< tab >}}
41
+ **Prerequisites**
42
+
43
+ You'll need at least `build-essential` and `libclang-dev` installed to build Itsi on Linux.
44
+ E.g.
45
+ ```bash
46
+ apt-get install build-essential libclang-dev
47
+ ```
48
+
49
+ Then use `gem` to install the Itsi package. This will in turn install both the
50
+ `itsi-server` gem, and the `itsi-scheduler` gem.
51
+
52
+
53
+ ```bash
54
+ gem install itsi-scheduler
55
+ ```
56
+
57
+ {{< callout type="info" >}}
58
+ Are you looking for Itsi server too? In this case, use `gem install itsi` (to get both Itsi scheduler and server)
59
+ Or `gem install itsi-server` to install just Itsi Server.
60
+ {{< /callout >}}
61
+
62
+ {{< /tab >}}
63
+ {{< tab >}}
64
+ **Mac**:
65
+ ```bash
66
+ gem install itsi-scheduler
67
+ ```
68
+ {{< callout type="info" >}}
69
+ Are you looking for Itsi server too? In this case, use `gem install itsi` (to get both Itsi scheduler and server)
70
+ Or `gem install itsi-server` to install just Itsi Server.
71
+ {{< /callout >}}
72
+
73
+ {{< /tab >}}
74
+ {{< tab >}}**Windows**: Itsi currently doesn't support native Windows builds, but it runs great on [https://learn.microsoft.com/en-us/windows/wsl/install](WSL).
75
+
76
+ Follow the linked instructions to Install a linux distribution like Ubuntu or Debian and then follow the instructions in the Linux tab.
77
+ {{< /tab >}}
78
+
79
+ {{< /tabs >}}
80
+
81
+ ### 2 - Use Itsi Scheduler
82
+
83
+ Great! You now have Itsi Scheduler installed.
84
+ Now you can run code like this:
85
+
86
+ ```ruby
87
+ require 'itsi/scheduler'
88
+ require 'socket'
89
+ results = Thread.new do
90
+ Fiber.set_scheduler Itsi::Scheduler.new
91
+ results = []
92
+ Fiber.schedule do
93
+ results << Addrinfo.getaddrinfo("www.ruby-lang.org", 80, nil, :STREAM)
94
+ end
95
+ Fiber.schedule do
96
+ results << Addrinfo.getaddrinfo("www.google.com", 80, nil, :STREAM)
97
+ end
98
+ results
99
+ end.value
100
+
101
+ puts results.map(&:inspect)
102
+ ```
103
+
104
+ to run many blocking operations simultaneously all while occupying only a single Ruby thread!
105
+ {{% /steps %}}
Binary file