diff options
| author | Ryan Dahl <ry@tinyclouds.org> | 2018-11-14 17:36:34 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-11-14 17:36:34 -0800 |
| commit | 3c8d2bde685d015721b1c0fd6f2a3ae54c156583 (patch) | |
| tree | 0f770fccbe23bd5a410612678176b449651cd8ad /src/msg.fbs | |
| parent | 765863e87aea725301d5f528b6de15bfa6022d46 (diff) | |
Support request method and headers in fetch() (#1188)
Adds a general HttpHeader flatbuffer message for serializing requests
and responses.
Diffstat (limited to 'src/msg.fbs')
| -rw-r--r-- | src/msg.fbs | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/src/msg.fbs b/src/msg.fbs index 7fdc73946..2a9c013a3 100644 --- a/src/msg.fbs +++ b/src/msg.fbs @@ -194,18 +194,26 @@ table KeyValue { value: string; } -table Fetch { - id: uint; +// Note this represents The WHOLE header of an http message, not just the key +// value pairs. That means it includes method and url for Requests and status +// for responses. This is why it is singular "Header" instead of "Headers". +table HttpHeader { + is_request: bool; + // Request only: + method: string; url: string; - // TODO Supply request headers: - // header_line: [string]; + // Response only: + status: uint16; + // Both: + fields: [KeyValue]; +} + +table Fetch { + header: HttpHeader; } table FetchRes { - id: uint; - status: int; - header_key: [string]; - header_value: [string]; + header: HttpHeader; body_rid: uint32; } |
