You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There have been various extensions to the text protocol starting in memcached 1.5.19, called the "meta protocol", making it on par with the binary protocol. This is still experimental, but I assume some stable form of it would get added in the near future (https://github.com/memcached/memcached/wiki/MetaCommands), but I'm filing this to
Track the existence of something that users may want as they update their memcache clients and servers months or years in the future, when the meta protocol API is no longer experimental.
Help users searching for whether twemproxy supports meta commands
NOTE: These commands are new. Please let us know if you run into any trouble with the API or the documentation! The meta protocol is no longer considered experimental, please give it a shot!
I think this is low urgency - I don't think any common clients mandate the meta protocol, but it may improve performance by sending fewer bytes in some cases (haven't read through the protocol to see if there'd be more byte buffer copying with struct mbuf)
(as well as allowing clients to combine multiple commands into one, e.g. get and bump TTL, or to fetch the remaining TTL of a key)
This release contains an experimental new protocol extension for the default
Text Protocol. This extension includes a flexible set of new commands
encompassing features previously unique to the binary protocol, as well as
many new updates allowing a reduction of network roundtrips for advanced
features.
For details, please see the "Meta Commands" section in doc/protocol.txt https://github.com/memcached/memcached/blob/master/doc/protocol.txt
If anyone works on a patch for this, I'd be interested in knowing.
Expected behavior
Support proxying requests from clients sending meta commands in the memcache text protocol, when the API is finalized
Actual behavior
Commands such as mg (multi-get) from https://github.com/memcached/memcached/blob/master/doc/protocol.txt are unsupported
It looks like the parser would need to be updated to allow those commands with a single key in the first position, and any number of flags, and the response parser would need to be updated to recognize the new 2-character response codes and which ones are associated with a value (VA), and so on
EDIT: As of 2021-05-01, this is still experimental. In older 1.5 releases, the protocol was different
An example session, with responses manually modified to add > for readability (expires/noexpires are arbitrarily chosen data values for keys with a ttl and with no TTL (T70 = 70 second ttl).
version
> VERSION 1.6.9
ms key T70 S7
expires
> OK
mg key t v
> VA 7 t63
> expires
mg key t v
> VA 7 t57
> expires
ms key S8
noexpire
> OK
mg key t c f h k l q s u v
> VA 8 t-1 c3 f0 h0 kkey l43 s8
> noexpire
The text was updated successfully, but these errors were encountered:
TysonAndre
changed the title
(Experimental) memcached meta commands support for text protocol
memcached meta commands support for text protocol
Nov 1, 2022
There have been various extensions to the text protocol starting in memcached 1.5.19, called the "meta protocol", making it on par with the binary protocol.
This is still experimental, but I assume some stable form of it would get added in the near future(https://github.com/memcached/memcached/wiki/MetaCommands), but I'm filing this toEDIT: https://github.com/memcached/memcached/wiki/MetaCommands#memcached-text-protocol-meta-commands as of 2021, it's also no longer experimental
I think this is low urgency - I don't think any common clients mandate the meta protocol, but it may improve performance by sending fewer bytes in some cases (haven't read through the protocol to see if there'd be more byte buffer copying with
struct mbuf
)(as well as allowing clients to combine multiple commands into one, e.g. get and bump TTL, or to fetch the remaining TTL of a key)
If anyone works on a patch for this, I'd be interested in knowing.
Expected behavior
Support proxying requests from clients sending meta commands in the memcache text protocol, when the API is finalized
Actual behavior
Commands such as
mg
(multi-get) from https://github.com/memcached/memcached/blob/master/doc/protocol.txt are unsupportedIt looks like the parser would need to be updated to allow those commands with a single key in the first position, and any number of flags, and the response parser would need to be updated to recognize the new 2-character response codes and which ones are associated with a value (
VA
), and so onEDIT: As of 2021-05-01, this is still experimental. In older 1.5 releases, the protocol was differentAccording to https://github.com/memcached/memcached/blob/master/doc/protocol.txt
this is still experimental in 1.6.9(this is no longer experimental)Meta Commands [EXPERIMENTAL: MAY CHANGE]
An example session, with responses manually modified to add
>
for readability (expires/noexpires are arbitrarily chosen data values for keys with a ttl and with no TTL (T70 = 70 second ttl).The text was updated successfully, but these errors were encountered: