413

状態符号 413 (HTTP)

[416] 413 (Payload Too Large) は、要求payloadの処理できるサイズよりも大きいことを表す状態符号です。

仕様書

意味

[4] 413 は、要求payloadが処理する意志がある、 あるいは処理できるよりも大きいために要求を拒むことを示しています >>1

構文

[415] は、この状態が一時的なものである場合、クライアントが再試行してもよい時刻を表す Retry-After: ヘッダー生成するべきです >>1

処理

[414] は、クライアント要求を継続することを防ぐため、 接続を閉じても構いません >>1

[417] 接続を閉じない場合には、通常の HTTP の規則に従い当該要求を末尾まで読み飛ばさなければなりません。

[418] クライアント要求を送信した途中で 413 を受信した場合、 Transfer-Encoding: chunked なら直近の chunk の後最後の chunk を送信して要求の送信を終えられますし、 Transfer-Encoding:Content-Length: もなければ任意の位置でHTTP接続を閉じることで終えられますが、 Content-Length: を指定している場合には、 その長さまで要求を送信しなければなりません。

そうしなければメッセージの終端位置を正しく決定できません。

関連

[6] 要求本体も参照。

実装

[8] nginx応答本体の最大サイズを設定ファイルの client_max_body_size で指定できるようにしており、それを超えると 413 を返します。 既定値は 1MB です。 >>7

歴史

[2] RFC 2068 & 2616 (HTTP/1.1) 10.4.14 413 Request Entity Too Large

The server is refusing to process a request because the request entity is larger than the server is willing or able to process. The server may MAY close the connection to prevent the client from continuing the request.

サーバーは、その処理する意思がある、又は処理することができるのよりも要求された実態が大きいがために、要求を処理するのを拒否しています。 サーバーは、クライアントが要求を継続するのを防ぐために接続を閉じても構いません

If the condition is temporary, the server SHOULD include a Retry-After header field to indicate that it is temporary and after what time the client may MAY try again.

この状況が一時的なものであれば、サーバーは Retry-After 頭欄を含めてこれが一時的であって、どれだけの時間の後クライアントが再挑戦しても構わないかを示すべきです

[5] Creating Custom Search Engines programmatically  |  Custom Search  |  Google Developers ( 版) <https://developers.google.com/custom-search/docs/api#table_ondemand>

413 - File too large The XML that is being submitted exceeds the Custom Search limit.

Verify that your file is not exceeding the size limit, which is documented on the Selecting Sites to Search page and the Promotions page.

If you are certain that the file size doesn't exceed the limit, try again later.