If the redis protocol is so compressible, maybe this behavior should be integrated as a protocol option like [1]?
[1] http://dev.mysql.com/doc/refman/5.5/en/replication-options-s...
If the redis protocol is so compressible, maybe this behavior should be integrated as a protocol option like [1]?
[1] http://dev.mysql.com/doc/refman/5.5/en/replication-options-s...
For the replication link it's easy to imagine a simple way to encode command names as operation IDs, the same for prefixed length stuff. So now you have:
*3
$3
SET
$3
foo
$3
bar
But this may become like: <set-opcode><2><3>foo<3>bar where the opcode is 1 byte, and the rest of the prefixed lengths are variable depending on the argument size, but most of the times 1 or two bytes. This of course is much more compact.However it's not bad to have the current format to be exactly like the AOF, and the client protocol itself, so everything is the same currently... and is future/backward compatible without issues. But well performances always have some price.
Since I'm tempted to set this up myself (not for Redis though), what is the alternative?
I've only used it for tunnelling some traffic out of my home network to a VPS but it's been rock solid for me over several years of frequent use.
I suspect (guess) that not having an idle connection help the tunnel to not randomly drop.
Have you simulated a network partition? How does redis handle the reconnect?
However we also use ssh tunnels for our continuous integration (jenkins) and the irc bots that we use for development (http://3scale.github.com/2012/06/29/irc-driven-development-p...).
In this setup we have the autossh going awol every one or two weeks. But as the blog post mentions, the ssh tunnel runs between our HQ (fiber) and Amazon, not very reliable. Furthermore, there is a lot of idle periods, which seems to trigger most of the issues. We cannot give more specifics since we forcefully just restart the daemon with a monit/munin combo.
The outbound firewall of our company drops my outbound ssh connections if they are idle for just 5 minutes. Adding:-
Host *
ServerAliveInterval 60
in my ~/.ssh/config file prevented most of the drops (the rest are explained by proper network outages or my DSL connection at home flapping.)A corresponding ClientAliveInterval setting in the sshd_config file also helps mask the problem [EDIT] if I ssh home from a machine at work that doesn't share my home directory ssh config file.