Open brycebaril opened 11 years ago
That would be awesome! I have to keep the current approach around as a shim (because polyfills like this aren't super useful if they dictate a minimum version of the thing they're patching), but anything that saved cycles on hot paths would be useful.
This isn't anything you don't know, but I find it nice to have it in front of me to reference. The flow of a typical command is (using
get
in this example):I haven't tried this, but one possible alternative approach would be to have node_redis expose the
Command
type, and the wrapper could modify or provide an alternateCommand
type that does the wrapping vs wrapping send_command.I don't know if it is any better, but at the very least it would save the args sniffing.