Please create issues to document your critiques, suggestions, improvements, etc. We will use it as a discussion funnel to refine this specification and move forward towards a stable 1.0
may contain any uppercase letter or digit or _ to describe the command
the first preference field is describing the compression codec of the request headers & body in all lowercase letters or digits or _
the second preference field is the list of supported compression codecs for the response in order from most preferred to least preferred separated by commas and preferences in all lowercase letters or digits or _
none can be specified to indicate no compression is to be used on the header or body data.
headers and body are both BSON data payloads which are separately compressed and encoded -- the idea is to keep the headers lightweight so packets can be partially processed without having to decode the whole body in every case.
example of a wire protocol message
# Request (empty headers and body)
EWP 0.1 PING none none 0 0
# Response
200 none 0 0
# Request (empty headers, bson body)
EWP 0.1 HELLO deflate gzip,snappy 0 1234
<1234 bytes of deflate compressed binary bson body data>
# Response
200 gzip 321 1234
<321 bytes of gzip compressed binary bson header data>
<1234 bytes of gzip compressed binary bson body data>
# Request (no compression, bson headers, bson body)
EWP 0.1 HELLO none none 321 1234
<321 bytes of binary bson header data>
<1234 bytes of binary bson body data>
# Response
200 none 0 0