BREW

要求メソッド BREW (HTTP)

[1] BREW は、珈琲ポットを制御する命令を送信することを表す要求メソッドです。

仕様書

意味

[3] HTCPCP においては BREWPOST と等価です >>2, >>4 が、「post」は珈琲商標であるため >>2、 代替として追加されました。

構文

[14] HTCPCPBREW 要求では、 payload bodyMIME型message/coffeepot でなければなりません >>15

[5] application/coffee-pot-command を使う >>2 ともありますが、誤りとされています (message/coffeepot 参照)。

[9] HTCPCP-TEA では message/teapot を使います >>4

[12] message/coffeepot を送ると HTCPCP に従う珈琲ポットが直ちに動作しますから、 を望んでいた場合その応答Alternates: ヘッダーから選び直すのでは珈琲が無駄になってしまいます。 従って最初から message/teapot を送るべきです >>11

処理モデル

[6] HTCPCP 珈琲ポットは、 POSTBREW を等価として扱わなければなりません >>2

[8] HTCPCP-TEA では URLパスごとに処理の方法が規定されています。 message/teapotBREW 要求を受信したら、 それに従って処理しなければなりません >>4

coffee: 参照。
[10] message/teapot 以外で指定された場合の処理は規定されていません。

歴史

[7] RFC 2324 (HTCPCP/1.0) 2.1.1 The BREW method, and the use of POST

Commands to control a coffee pot are sent from client to coffee server using either the BREW or POST method, and a message body with Content-Type set to "application/coffee-pot-command".

珈琲ポットを制御する命令は、 クライアントから珈琲鯖に BREW method 又は POST method を使って、 メッセージ本体の Content-Typeapplication/coffee-pot-command に設定して送信します。

A coffee pot server MUST accept both the BREW and POST method equivalently. However, the use of POST for causing actions to happen is deprecated.

珈琲ポット鯖は、 BREW method も POST method も同等に受け入れなければなりません。 しかし、行動を起こす時に POST を使用することは非推奨です。

Coffee pots heat water using electronic mechanisms, so there is no fire. Thus, no firewalls are necessary, and firewall control policy is irrelevant. However, POST may be a trademark for coffee, and so the BREW method has been added. The BREW method may be used with other HTTP-based protocols (e.g., the Hyper Text Brewery Control Protocol).

珈琲ポットは電子的機構を使って水を熱するので、 火は使いません。従って、防火壁は不要であり、 防火壁制御方針も無関係です。しかし、 POST は珈琲に関しては商標かもしれないので、 BREW method が追加されました。 BREW method は他の HTTP を基にしたプロトコル (例えばハイパーテキスト醸造制御プロトコル) でも使われるかもしれません。