summaryrefslogtreecommitdiff
path: root/benchmarks/command_packer_benchmark.py
diff options
context:
space:
mode:
Diffstat (limited to 'benchmarks/command_packer_benchmark.py')
-rw-r--r--benchmarks/command_packer_benchmark.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/benchmarks/command_packer_benchmark.py b/benchmarks/command_packer_benchmark.py
index 13d6f97..49f48f2 100644
--- a/benchmarks/command_packer_benchmark.py
+++ b/benchmarks/command_packer_benchmark.py
@@ -30,7 +30,7 @@ class StringJoiningConnection(Connection):
"Pack a series of arguments into a value Redis command"
args_output = SYM_EMPTY.join([
SYM_EMPTY.join((SYM_DOLLAR, b(str(len(k))), SYM_CRLF, k, SYM_CRLF))
- for k in imap(self.encode, args)])
+ for k in imap(self.encoder.encode, args)])
output = SYM_EMPTY.join(
(SYM_STAR, b(str(len(args))), SYM_CRLF, args_output))
return output
@@ -63,7 +63,7 @@ class ListJoiningConnection(Connection):
buff = SYM_EMPTY.join(
(SYM_STAR, b(str(len(args))), SYM_CRLF))
- for k in imap(self.encode, args):
+ for k in imap(self.encoder.encode, args):
if len(buff) > 6000 or len(k) > 6000:
buff = SYM_EMPTY.join(
(buff, SYM_DOLLAR, b(str(len(k))), SYM_CRLF))