github.com/krum110487/go-htaccess@v0.0.0-20240316004156-60641c8e7598/tests/data/apache_2_2_34/manual/mod/mod_mem_cache.html.ja.utf8 (about) 1 <?xml version="1.0" encoding="UTF-8"?> 2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 3 <html xmlns="http://www.w3.org/1999/xhtml" lang="ja" xml:lang="ja"><head> 4 <meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /> 5 <!-- 6 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 7 This file is generated from xml source: DO NOT EDIT 8 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 9 --> 10 <title>mod_mem_cache - Apache HTTP サーバ バージョン 2.2</title> 11 <link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" /> 12 <link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" /> 13 <link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" /> 14 <script src="../style/scripts/prettify.min.js" type="text/javascript"> 15 </script> 16 17 <link href="../images/favicon.ico" rel="shortcut icon" /><link href="http://httpd.apache.org/docs/current/mod/mod_mem_cache.html" rel="canonical" /></head> 18 <body> 19 <div id="page-header"> 20 <p class="menu"><a href="../mod/">モジュール</a> | <a href="../mod/directives.html">ディレクティブ</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">用語</a> | <a href="../sitemap.html">サイトマップ</a></p> 21 <p class="apache">Apache HTTP サーバ バージョン 2.2</p> 22 <img alt="" src="../images/feather.gif" /></div> 23 <div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div> 24 <div id="path"> 25 <a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP サーバ</a> > <a href="http://httpd.apache.org/docs/">ドキュメンテーション</a> > <a href="../">バージョン 2.2</a> > <a href="./">モジュール</a></div> 26 <div id="page-content"> 27 <div class="retired"><h4>Please note</h4> 28 <p> This document refers to a legacy release (<strong>2.2</strong>) of Apache httpd. The active release (<strong>2.4</strong>) is documented <a href="http://httpd.apache.org/docs/current">here</a>. If you have not already upgraded, please follow <a href="http://httpd.apache.org/docs/current/upgrading.html">this link</a> for more information.</p> 29 <p>You may follow <a href="http://httpd.apache.org/docs/current/mod/mod_mem_cache.html">this link</a> to go to the current version of this document.</p></div><div id="preamble"><h1>Apache モジュール mod_mem_cache</h1> 30 <div class="toplang"> 31 <p><span>翻訳済み言語: </span><a href="../en/mod/mod_mem_cache.html" hreflang="en" rel="alternate" title="English"> en </a> | 32 <a href="../ja/mod/mod_mem_cache.html" title="Japanese"> ja </a> | 33 <a href="../ko/mod/mod_mem_cache.html" hreflang="ko" rel="alternate" title="Korean"> ko </a></p> 34 </div> 35 <div class="outofdate">この日本語訳はすでに古くなっている 36 可能性があります。 37 最近更新された内容を見るには英語版をご覧下さい。 38 </div> 39 <table class="module"><tr><th><a href="module-dict.html#Description">説明:</a></th><td>URI をキーにしたコンテンツのキャッシュ</td></tr> 40 <tr><th><a href="module-dict.html#Status">ステータス:</a></th><td>Extension</td></tr> 41 <tr><th><a href="module-dict.html#ModuleIdentifier">モジュール識別子:</a></th><td>mem_cache_module</td></tr> 42 <tr><th><a href="module-dict.html#SourceFile">ソースファイル:</a></th><td>mod_mem_cache.c</td></tr></table> 43 <h3>概要</h3> 44 45 <p>このモジュールは <code class="module"><a href="../mod/mod_cache.html">mod_cache</a></code> を<em>必要とします</em>。 46 これは <code class="module"><a href="../mod/mod_cache.html">mod_cache</a></code> のサポートモジュールとして 47 動作し、メモリを使用したストレージ管理機構を提供します。 48 <code class="module"><a href="../mod/mod_mem_cache.html">mod_mem_cache</a></code> は二つのモードのどちらかで動作するように 49 設定できます: ファイル記述子のキャッシュかヒープ中のオブジェクトの 50 キャッシュです。ローカルで生成されたコンテンツに対してキャッシュするときや、 51 <code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code> を使って <code class="directive"><a href="../mod/mod_proxy.html#proxypass">ProxyPass</a></code> (つまり<dfn>リバースプロキシ</dfn>向け) に設定したときのバックエンドサーバのコンテンツに対して 52 キャッシュをするときに、たいへん効果的です。</p> 53 54 <p>コンテンツのキャッシュへの保存と取得は URI に基づいたキーが使われます。 55 アクセス保護のかけられているコンテンツはキャッシュされません。</p> 56 </div> 57 <div id="quickview"><h3 class="directives">ディレクティブ</h3> 58 <ul id="toc"> 59 <li><img alt="" src="../images/down.gif" /> <a href="#mcachemaxobjectcount">MCacheMaxObjectCount</a></li> 60 <li><img alt="" src="../images/down.gif" /> <a href="#mcachemaxobjectsize">MCacheMaxObjectSize</a></li> 61 <li><img alt="" src="../images/down.gif" /> <a href="#mcachemaxstreamingbuffer">MCacheMaxStreamingBuffer</a></li> 62 <li><img alt="" src="../images/down.gif" /> <a href="#mcacheminobjectsize">MCacheMinObjectSize</a></li> 63 <li><img alt="" src="../images/down.gif" /> <a href="#mcacheremovalalgorithm">MCacheRemovalAlgorithm</a></li> 64 <li><img alt="" src="../images/down.gif" /> <a href="#mcachesize">MCacheSize</a></li> 65 </ul> 66 <h3>参照</h3> 67 <ul class="seealso"> 68 <li><code class="module"><a href="../mod/mod_cache.html">mod_cache</a></code></li> 69 <li><code class="module"><a href="../mod/mod_disk_cache.html">mod_disk_cache</a></code></li> 70 </ul><ul class="seealso"><li><a href="#comments_section">コメント</a></li></ul></div> 71 72 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> 73 <div class="directive-section"><h2><a name="MCacheMaxObjectCount" id="MCacheMaxObjectCount">MCacheMaxObjectCount</a> <a name="mcachemaxobjectcount" id="mcachemaxobjectcount">ディレクティブ</a></h2> 74 <table class="directive"> 75 <tr><th><a href="directive-dict.html#Description">説明:</a></th><td>キャッシュに保管されるオブジェクトの最大数</td></tr> 76 <tr><th><a href="directive-dict.html#Syntax">構文:</a></th><td><code>MCacheMaxObjectCount <var>value</var></code></td></tr> 77 <tr><th><a href="directive-dict.html#Default">デフォルト:</a></th><td><code>MCacheMaxObjectCount 1009</code></td></tr> 78 <tr><th><a href="directive-dict.html#Context">コンテキスト:</a></th><td>サーバ設定ファイル</td></tr> 79 <tr><th><a href="directive-dict.html#Status">ステータス:</a></th><td>Extension</td></tr> 80 <tr><th><a href="directive-dict.html#Module">モジュール:</a></th><td>mod_mem_cache</td></tr> 81 </table> 82 <p><code class="directive">MCacheMaxObjectCount</code> ディレクティブは 83 キャッシュされるオブジェクトの最大数を指定します。 84 この値はハッシュテーブルを作成するときに使われます。 85 新しいオブジェクトを挿入するときに、オブジェクトの最大数に 86 達してしまっているとき、新しいオブジェクトをキャッシュできるように、 87 オブジェクトを一つ消去します。オブジェクトは 88 <code class="directive"><a href="#mcacheremovalalgorithm">MCacheRemovalAlgorithm</a></code> 89 で指定されたアルゴリズムに従って削除されます。</p> 90 91 <div class="example"><h3>例</h3><p><code> 92 MCacheMaxObjectCount 13001 93 </code></p></div> 94 95 </div> 96 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> 97 <div class="directive-section"><h2><a name="MCacheMaxObjectSize" id="MCacheMaxObjectSize">MCacheMaxObjectSize</a> <a name="mcachemaxobjectsize" id="mcachemaxobjectsize">ディレクティブ</a></h2> 98 <table class="directive"> 99 <tr><th><a href="directive-dict.html#Description">説明:</a></th><td>キャッシュに保管できるドキュメントの最大サイズ (バイト)</td></tr> 100 <tr><th><a href="directive-dict.html#Syntax">構文:</a></th><td><code>MCacheMaxObjectSize <var>bytes</var></code></td></tr> 101 <tr><th><a href="directive-dict.html#Default">デフォルト:</a></th><td><code>MCacheMaxObjectSize 10000</code></td></tr> 102 <tr><th><a href="directive-dict.html#Context">コンテキスト:</a></th><td>サーバ設定ファイル</td></tr> 103 <tr><th><a href="directive-dict.html#Status">ステータス:</a></th><td>Extension</td></tr> 104 <tr><th><a href="directive-dict.html#Module">モジュール:</a></th><td>mod_mem_cache</td></tr> 105 </table> 106 <p><code class="directive">MCacheMaxObjectSize</code> はドキュメントを 107 キャッシュするかどうかを判定する、最大のサイズをバイト数で設定します。</p> 108 109 <div class="example"><h3>例</h3><p><code> 110 MCacheMaxObjectSize 6400000 111 </code></p></div> 112 113 <div class="note"><h3>注</h3> 114 <p><code class="directive">MCacheMaxObjectSize</code> の値は <code class="directive"><a href="#mcacheminobjectsize">MCacheMinObjectSize</a></code> 115 で指定した値よりも大きくなければなりません。</p> 116 </div> 117 118 </div> 119 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> 120 <div class="directive-section"><h2><a name="MCacheMaxStreamingBuffer" id="MCacheMaxStreamingBuffer">MCacheMaxStreamingBuffer</a> <a name="mcachemaxstreamingbuffer" id="mcachemaxstreamingbuffer">ディレクティブ</a></h2> 121 <table class="directive"> 122 <tr><th><a href="directive-dict.html#Description">説明:</a></th><td>ストリームされている応答をキャッシュ不能と決定するまでに 123 メモリにバッファする最大量</td></tr> 124 <tr><th><a href="directive-dict.html#Syntax">構文:</a></th><td><code>MCacheMaxStreamingBuffer <var>size_in_bytes</var></code></td></tr> 125 <tr><th><a href="directive-dict.html#Default">デフォルト:</a></th><td><code>MCacheMaxStreamingBuffer of 100000 か MCacheMaxObjectSize の少い方</code></td></tr> 126 <tr><th><a href="directive-dict.html#Context">コンテキスト:</a></th><td>サーバ設定ファイル</td></tr> 127 <tr><th><a href="directive-dict.html#Status">ステータス:</a></th><td>Extension</td></tr> 128 <tr><th><a href="directive-dict.html#Module">モジュール:</a></th><td>mod_mem_cache</td></tr> 129 </table> 130 <p><code class="directive">MCacheMaxStreamingBuffer</code> ディレクティブは、 131 サイズが大きすぎてキャッシュできないと判断するまでの、 132 ストリーム応答のバッファのための最大バイト数を指定します。 133 ストリーム応答とは、コンテンツの全体がすぐには得られず、 134 <code>Content-Length</code> がわからない応答を指します。 135 ストリーム応答を行なうようなものにはプロキシされた応答や、 136 CGI スクリプトの出力などがあります。デフォルトではストリームの応答は 137 <code>Content-Length</code> がない限りキャッシュ<em>されません</em>。 138 このような動作になっている理由は、結局キャッシュに収まりきらないと 139 判断することになってしまうような、サイズの大きな応答のバッファリングに、 140 大量のメモリが消費されるのを避けるためです。 141 <code class="directive">MCacheMaxStreamingBuffer</code> ディレクティブを使うと、 142 <code>Content-Length</code> を含まない応答に対して指定された最大量まで 143 バッファするようにできます。バッファを使い切ると、バッファ中の 144 コンテンツは捨てられ、キャッシュ動作を中止します。</p> 145 146 <div class="note"><h3>注:</h3> 147 <p><code class="directive">MCacheMaxStreamingBuffer</code> に非零の値を 148 使っても、クライアントへの応答の転送に特に遅延は発生しません。 149 <code class="module"><a href="../mod/mod_mem_cache.html">mod_mem_cache</a></code> はストリームコンテンツの断片を 150 バッファにコピーした後、即座に、その部分をクライアントへの配送の 151 次段の出力フィルタに送ります。</p> 152 </div> 153 154 <div class="example"><p><code> 155 # Enable caching of streamed responses up to 64KB:<br /> 156 MCacheMaxStreamingBuffer 65536 157 </code></p></div> 158 159 </div> 160 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> 161 <div class="directive-section"><h2><a name="MCacheMinObjectSize" id="MCacheMinObjectSize">MCacheMinObjectSize</a> <a name="mcacheminobjectsize" id="mcacheminobjectsize">ディレクティブ</a></h2> 162 <table class="directive"> 163 <tr><th><a href="directive-dict.html#Description">説明:</a></th><td>キャッシュに保管されるドキュメントの最小サイズ (バイト)</td></tr> 164 <tr><th><a href="directive-dict.html#Syntax">構文:</a></th><td><code>MCacheMinObjectSize <var>bytes</var></code></td></tr> 165 <tr><th><a href="directive-dict.html#Default">デフォルト:</a></th><td><code>MCacheMinObjectSize 0</code></td></tr> 166 <tr><th><a href="directive-dict.html#Context">コンテキスト:</a></th><td>サーバ設定ファイル</td></tr> 167 <tr><th><a href="directive-dict.html#Status">ステータス:</a></th><td>Extension</td></tr> 168 <tr><th><a href="directive-dict.html#Module">モジュール:</a></th><td>mod_mem_cache</td></tr> 169 </table> 170 <p><code class="directive">MCacheMinObjectSize</code> ディレクティブは、ドキュメントを 171 キャッシュするかどうかを判定する、最小のサイズをバイト数で設定します。</p> 172 173 <div class="example"><h3>例</h3><p><code> 174 MCacheMinObjectSize 10000 175 </code></p></div> 176 177 </div> 178 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> 179 <div class="directive-section"><h2><a name="MCacheRemovalAlgorithm" id="MCacheRemovalAlgorithm">MCacheRemovalAlgorithm</a> <a name="mcacheremovalalgorithm" id="mcacheremovalalgorithm">ディレクティブ</a></h2> 180 <table class="directive"> 181 <tr><th><a href="directive-dict.html#Description">説明:</a></th><td>キャッシュから削除するドキュメントを選ぶためのアルゴリズム</td></tr> 182 <tr><th><a href="directive-dict.html#Syntax">構文:</a></th><td><code>MCacheRemovalAlgorithm LRU|GDSF</code></td></tr> 183 <tr><th><a href="directive-dict.html#Default">デフォルト:</a></th><td><code>MCacheRemovalAlgorithm GDSF</code></td></tr> 184 <tr><th><a href="directive-dict.html#Context">コンテキスト:</a></th><td>サーバ設定ファイル</td></tr> 185 <tr><th><a href="directive-dict.html#Status">ステータス:</a></th><td>Extension</td></tr> 186 <tr><th><a href="directive-dict.html#Module">モジュール:</a></th><td>mod_mem_cache</td></tr> 187 </table> 188 <p><code class="directive">MCacheRemovalAlgorithm</code> ディレクティブは、 189 キャッシュから削除するドキュメントを選択するためのアルゴリズムを 190 指定します。選択肢は二つあります:</p> 191 192 <dl> 193 <dt><code>LRU</code> (Least Recently Used)</dt> 194 <dd><code>LRU</code> 一番長くアクセスされていないドキュメントを削除します。 195 </dd> 196 197 <dt><code>GDSF</code> (GreadyDual-Size)</dt> 198 <dd><code>GDSF</code> はキャッシュミスのコストとドキュメントのサイズをもとに、 199 ドキュメントのキャッシュに対して優先度をつけます。 200 優先度の一番低いドキュメントが最初に削除されます。</dd> 201 </dl> 202 203 <div class="example"><h3>例</h3><p><code> 204 MCacheRemovalAlgorithm GDSF<br /> 205 MCacheRemovalAlgorithm LRU 206 </code></p></div> 207 208 </div> 209 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> 210 <div class="directive-section"><h2><a name="MCacheSize" id="MCacheSize">MCacheSize</a> <a name="mcachesize" id="mcachesize">ディレクティブ</a></h2> 211 <table class="directive"> 212 <tr><th><a href="directive-dict.html#Description">説明:</a></th><td>キャッシュに使われるメモリの最大量をバイト単位で指定</td></tr> 213 <tr><th><a href="directive-dict.html#Syntax">構文:</a></th><td><code>MCacheSize <var>KBytes</var></code></td></tr> 214 <tr><th><a href="directive-dict.html#Default">デフォルト:</a></th><td><code>MCacheSize 100</code></td></tr> 215 <tr><th><a href="directive-dict.html#Context">コンテキスト:</a></th><td>サーバ設定ファイル</td></tr> 216 <tr><th><a href="directive-dict.html#Status">ステータス:</a></th><td>Extension</td></tr> 217 <tr><th><a href="directive-dict.html#Module">モジュール:</a></th><td>mod_mem_cache</td></tr> 218 </table> 219 <p><code class="directive">MCacheSize</code> ディレクティブはキャッシュに 220 使われるメモリの大きさをキロバイト (1024 バイト単位) で設定します。 221 新しいオブジェクトをキャッシュに挿入することになり、オブジェクトの 222 サイズが残りのメモリより大きい場合は、その新しいオブジェクトの挿入が 223 可能になるまで、古いオブジェクトが削除されていきます。 224 オブジェクトは <code class="directive"><a href="#mcacheremovalalgorithm">MCacheRemovalAlgorithm</a></code> 225 で指定したアルゴリズムに従って削除されます。</p> 226 227 <div class="example"><h3>例</h3><p><code> 228 MCacheSize 700000 229 </code></p></div> 230 231 <div class="note"><h3>注</h3> 232 <p><code class="directive">MCacheSize</code> の値は <code class="directive"><a href="#mcachemaxobjectsize">MCacheMaxObjectSize</a></code> ディレクティブで指定した値より 233 大きくなければなりません。</p> 234 </div> 235 236 </div> 237 </div> 238 <div class="bottomlang"> 239 <p><span>翻訳済み言語: </span><a href="../en/mod/mod_mem_cache.html" hreflang="en" rel="alternate" title="English"> en </a> | 240 <a href="../ja/mod/mod_mem_cache.html" title="Japanese"> ja </a> | 241 <a href="../ko/mod/mod_mem_cache.html" hreflang="ko" rel="alternate" title="Korean"> ko </a></p> 242 </div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">コメント</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed again by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Freenode, or sent to our <a href="http://httpd.apache.org/lists.html">mailing lists</a>.</div> 243 <script type="text/javascript"><!--//--><![CDATA[//><!-- 244 var comments_shortname = 'httpd'; 245 var comments_identifier = 'http://httpd.apache.org/docs/2.2/mod/mod_mem_cache.html'; 246 (function(w, d) { 247 if (w.location.hostname.toLowerCase() == "httpd.apache.org") { 248 d.write('<div id="comments_thread"><\/div>'); 249 var s = d.createElement('script'); 250 s.type = 'text/javascript'; 251 s.async = true; 252 s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier; 253 (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s); 254 } 255 else { 256 d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>'); 257 } 258 })(window, document); 259 //--><!]]></script></div><div id="footer"> 260 <p class="apache">Copyright 2017 The Apache Software Foundation.<br />この文書は <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a> のライセンスで提供されています。.</p> 261 <p class="menu"><a href="../mod/">モジュール</a> | <a href="../mod/directives.html">ディレクティブ</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">用語</a> | <a href="../sitemap.html">サイトマップ</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!-- 262 if (typeof(prettyPrint) !== 'undefined') { 263 prettyPrint(); 264 } 265 //--><!]]></script> 266 </body></html>