-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
2024.11.15 19:23 fba741b91 Puma master
- Loading branch information
Showing
8 changed files
with
137 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,129 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
|
||
<meta charset='UTF-8'> | ||
<meta name='viewport' content='width=device-width, initial-scale=1.0, user-scalable=no'> | ||
<meta name='apple-touch-fullscreen' content='yes'> | ||
<meta name='apple-mobile-web-app-capable' content='yes'> | ||
<meta name='apple-mobile-web-app-status-bar-style' content='rgba(228,228,228,1.0)'> | ||
|
||
<title>File: Java Options — Puma master</title> | ||
|
||
<link rel='stylesheet' type='text/css' href='../css/y_fonts.css' /> | ||
<link rel='stylesheet' type='text/css' href='../css/highlight.github.css' /> | ||
<link rel='stylesheet' type='text/css' href='../css/y_style.css' /> | ||
<link rel='stylesheet' type='text/css' href='../css/y_list.css' /> | ||
<link rel='stylesheet' type='text/css' href='../css/y_color.css' /> | ||
|
||
<script type='text/javascript'> | ||
var pathId = "java_options", | ||
relpath = ''; | ||
|
||
var t2Info = { | ||
CSEP: '.', | ||
ISEP: '#', | ||
NSEP: '::' | ||
}; | ||
</script> | ||
|
||
<script type='text/javascript' charset='utf-8' src='../js/highlight.pack.js'></script> | ||
<script type='text/javascript' charset='utf-8' src='../js/y_app.js'></script> | ||
|
||
</head> | ||
<body> | ||
<svg id='y_wait' class viewBox='0 0 90 90'></svg> | ||
<div id='settings' class='hidden'></div> | ||
<div id='y_list' class='d h'> | ||
<header id='list_header'></header> | ||
<nav id= 'list_nav' class='y_nav l_nav'> | ||
<ul id='list_items'></ul> | ||
</nav> | ||
</div> | ||
<div id='y_toc' class='f h'> | ||
<header id='toc_header'></header> | ||
<nav id= 'toc_nav' class='y_nav t_nav'> | ||
<ol id='toc_items'></ol> | ||
</nav> | ||
</div> | ||
<div id='y_main' tabindex='-1'> | ||
<header id='y_header'> | ||
<div id='y_menu'> | ||
<a id='home_no_xhr' href='/'>Home</a> » | ||
<a href='.'>Puma master</a> » | ||
<a href='_index.html'>Index</a> » | ||
<span class='title'><a id='t2_doc_top' href='#'>File: Java Options ▲</a></span> | ||
</div> | ||
|
||
<a id='list_href' href="class_list.html"></a> | ||
<div id='y_measure_em' class='y_measure'></div> | ||
<div id='y_measure_vh' class='y_measure'></div> | ||
<span id='y_measure_50pre' class='y_measure'><code>123456789_123456789_123456789_123456789_123456789_</code></span> | ||
</header> | ||
<div id='content' class='file'> | ||
<h1>Java Options</h1> | ||
|
||
<p><code>System Properties</code> or <code>Environment Variables</code> can be used to change Puma's | ||
default configuration for its Java extension. The provided values are evaluated | ||
during initialization, and changes while running the app have no effect. | ||
Moreover, default values may be used in case of invalid inputs.</p> | ||
|
||
<h2>Supported Options</h2> | ||
|
||
<table><thead> | ||
<tr> | ||
<th>ENV Name</th> | ||
<th style="text-align: center">Default Value</th> | ||
<th style="text-align: center">Validation</th> | ||
</tr> | ||
</thead><tbody> | ||
<tr> | ||
<td>PUMA_QUERY_STRING_MAX_LENGTH</td> | ||
<td style="text-align: center">1024 * 10</td> | ||
<td style="text-align: center">Positive natural number</td> | ||
</tr> | ||
<tr> | ||
<td>PUMA_REQUEST_PATH_MAX_LENGTH</td> | ||
<td style="text-align: center">8192</td> | ||
<td style="text-align: center">Positive natural number</td> | ||
</tr> | ||
<tr> | ||
<td>PUMA_REQUEST_URI_MAX_LENGTH</td> | ||
<td style="text-align: center">1024 * 12</td> | ||
<td style="text-align: center">Positive natural number</td> | ||
</tr> | ||
</tbody></table> | ||
|
||
<h2>Examples</h2> | ||
|
||
<h3>Invalid inputs</h3> | ||
|
||
<p>An empty string will be handled as missing, and the default value will be used instead. | ||
<a href="Puma.html" title="Puma (module)"><code>Puma</code></a> will print an error message for other invalid values.</p> | ||
|
||
<pre class="code ruby"><code class="ruby"><span class='id identifier rubyid_foo'>foo</span><span class='ivar'>@bar</span><span class='op'>:</span><span class='op'>~</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>puma$ PUMA_QUERY_STRING_MAX_LENGTH=abc PUMA_REQUEST_PATH_MAX_LENGTH='' PUMA_REQUEST_URI_MAX_LENGTH=0 bundle exec bin</span><span class='regexp_end'>/puma</span></span> <span class='id identifier rubyid_test'>test</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>rackup</span><span class='regexp_end'>/hello</span></span>.<span class='id identifier rubyid_ru'>ru</span> | ||
|
||
<span class='const'>The</span> <span class='id identifier rubyid_value'>value</span> <span class='int'>0</span> <span class='kw'>for</span> <span class='const'>PUMA_REQUEST_URI_MAX_LENGTH</span> <span class='id identifier rubyid_is'>is</span> <span class='id identifier rubyid_invalid'>invalid</span>. <span class='const'>Using</span> <span class='id identifier rubyid_default'>default</span> <span class='id identifier rubyid_value'>value</span> <span class='int'>12288</span> <span class='id identifier rubyid_instead'>instead</span>. | ||
<span class='const'>The</span> <span class='id identifier rubyid_value'>value</span> <span class='id identifier rubyid_abc'>abc</span> <span class='kw'>for</span> <span class='const'>PUMA_QUERY_STRING_MAX_LENGTH</span> <span class='id identifier rubyid_is'>is</span> <span class='id identifier rubyid_invalid'>invalid</span>. <span class='const'>Using</span> <span class='id identifier rubyid_default'>default</span> <span class='id identifier rubyid_value'>value</span> <span class='int'>10240</span> <span class='id identifier rubyid_instead'>instead</span>. | ||
<span class='const'><a href="Puma.html" title="Puma (module)">Puma</a></span> <span class='id identifier rubyid_starting'>starting</span> <span class='kw'>in</span> <span class='id identifier rubyid_single'>single</span> <span class='id identifier rubyid_mode'>mode</span><span class='op'>...</span></code></pre> | ||
|
||
<h3>Valid inputs</h3> | ||
|
||
<pre class="code ruby"><code class="ruby"><span class='id identifier rubyid_foo'>foo</span><span class='ivar'>@bar</span><span class='op'>:</span><span class='op'>~</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>puma$ PUMA_REQUEST_PATH_MAX_LENGTH=9 bundle exec bin</span><span class='regexp_end'>/puma</span></span> <span class='id identifier rubyid_test'>test</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>rackup</span><span class='regexp_end'>/hello</span></span>.<span class='id identifier rubyid_ru'>ru</span> | ||
|
||
<span class='const'><a href="Puma.html" title="Puma (module)">Puma</a></span> <span class='id identifier rubyid_starting'>starting</span> <span class='kw'>in</span> <span class='id identifier rubyid_single'>single</span> <span class='id identifier rubyid_mode'>mode</span><span class='op'>...</span></code></pre> | ||
|
||
<pre class="code ruby"><code class="ruby"><span class='id identifier rubyid_foo'>foo</span><span class='ivar'>@bar</span><span class='op'>:</span><span class='op'>~</span> <span class='id identifier rubyid_export'>export</span> <span class='id identifier rubyid_path'>path</span><span class='op'>=</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>123456789 # 10 chars | ||
foo@bar:~ curl "http:</span><span class='regexp_end'>/</span></span><span class='op'>/</span><span class='id identifier rubyid_localhost'>localhost</span><span class='symbeg'>:</span><span class='int'>9292</span><span class='gvar'>$</span>{<span class='id identifier rubyid_path'>path</span>}<span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'> | ||
|
||
Puma caught this error: HTTP element REQUEST_PATH is longer than the 9 allowed length. (Puma::HttpParserError) | ||
|
||
foo@bar:~ export path=/12345678 # 9 chars | ||
foo@bar:~ curl </span><span class='tstring_end'>"</span></span><span class='id identifier rubyid_http'>http</span><span class='symbeg'>:</span><span class='op'>/</span><span class='op'>/</span><span class='id identifier rubyid_localhost'>localhost</span><span class='symbeg'>:</span><span class='int'>9292</span><span class='gvar'>$</span>{<span class='id identifier rubyid_path'>path</span>}<span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'> | ||
Hello World</span></code></pre> | ||
|
||
<div id='footer'></div> | ||
</div> <!-- content --> | ||
</div> <!-- y_main --> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters