1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-04 15:02:09 +03:00

399 Commits

Author SHA1 Message Date
Ruben Bridgewater
e6aa3826f7 Small speedup: do not call data.toString() on debug messages 2015-09-13 23:51:36 +02:00
Ruben Bridgewater
0925885a88 Do not wrap errors into other errors. The trace is going to be manipulated that way. 2015-09-12 21:59:17 +02:00
Ruben Bridgewater
b06985a219 Update commands list and remove unecessary code
Add use strict

Add changelog entry
2015-09-12 19:47:25 +02:00
Ruben Bridgewater
1c1c4ea446 Update readme about lower case commands 2015-09-12 19:17:02 +02:00
Ruben Bridgewater
4c6b84315e Tiny speedup by removing command.toLowerCase()
This is not necessary as the command itself is only used from inside the code and as they are (now) all lower case it is safe to remove the toLowerCase
2015-09-12 19:17:02 +02:00
Ruben Bridgewater
b63e980913 Merge pull request #825 from fintura/emitter
Remove event emitters from the parsers
2015-09-12 19:15:38 +02:00
Ruben Bridgewater
ba779ac361 Some small code style changes
Revert some done stuff
2015-09-12 18:56:49 +02:00
Ruben Bridgewater
06c5f1922b Add jshint and fix errors accordingly (including broken tests) 2015-09-12 18:56:49 +02:00
Benjamin E. Coe
a31a4e29e9 Merge pull request #819 from NodeRedis/815-tweaks
minor tweaks to how we spawn tests in #815
2015-09-11 21:40:48 -07:00
Ruben Bridgewater
0170145f74 Remove event emitters from the parser as they are overhead that is not needed 2015-09-05 17:10:27 +02:00
Ruben Bridgewater
159bc80653 Revert to old behavior 2015-09-04 15:37:47 +02:00
Ruben Bridgewater
9b1d262cdf Accept hmset being used without a callback. Closes #694 2015-09-04 15:21:59 +02:00
Ruben Bridgewater
03e696b476 Merge pull request #761 from vitaliylag/patch-1
Callback should be optional when using Array args. Closes #321 #502 #694 #398
2015-09-04 12:26:02 +02:00
Ruben Bridgewater
89e1f6f067 Improve code coverage by adding tests and removing unnecessary code 2015-09-03 22:26:01 +02:00
Ruben Bridgewater
62041c519f Test for statements instead of matching them if test is enough
precompile regex
2015-09-02 22:13:07 +02:00
Ruben Bridgewater
19db6d1dad Remove lib/util.js 2015-09-02 22:13:07 +02:00
Ruben Bridgewater
52db91c753 Fix js parser sending non-Errors 2015-09-02 22:13:07 +02:00
Ruben Bridgewater
e0d0649c60 Add fallback for node 0.10
Improve the fallback mode
2015-09-02 21:52:54 +02:00
Ruben Bridgewater
1eb30add66 Use util.debuglog instead of using different indidivudal styles for debugging 2015-09-02 21:49:11 +02:00
jomo
338b3cd9d8 Remove redundant check
If the first operand of the disjunction (`!obj.loading`) is false, `obj.loading` is truthy.
Thus there is no need to test it again in second operand.
2015-08-30 02:37:26 +02:00
Benjamin E. Coe
9796209550 Merge pull request #764 from Anubisss/master
A little optimization in a function if the client is closing.
2015-08-29 14:16:30 -07:00
Daniel Price
575ade907c Issue #512 send_command("monitoring") is doomed to fail 2015-08-21 14:57:48 -07:00
David Vas
86f1cef781 Merge remote-tracking branch 'node_redis/master' 2015-08-18 13:09:41 +02:00
Ruben Bridgewater
a2bc597212 Add simicolons
This is just a style change
2015-07-22 17:51:07 +02:00
Ruben Bridgewater
1f9e536ca0 Add use strict statements
This is going to improve the performance minimal and improves the safety of the code
2015-07-22 17:50:37 +02:00
Ruben Bridgewater
208b7874bf Rewrite createClient. Fixes #651 2015-07-22 17:15:12 +02:00
Raymond Myers
ded75c8ea2 Fixed detect_buffers keeping all multi/exec results as buffers 2015-07-11 22:47:25 -07:00
Raymond Myers
aea03d60be Fixed exec result arrays being stringed in detect_buffers mode 2015-07-11 22:47:25 -07:00
Raymond Myers
f384d1c774 Fixed the pub/sub logic accidentally stringing the first value of a multi/exec response 2015-07-11 22:47:25 -07:00
Raymond Myers
6f1acb0678 Fixed bug where buffer hgetall's in a multi would throw exceptions 2015-07-11 22:47:25 -07:00
David Vas
6af443639e A little optimization in a function if the client is closing. 2015-06-11 16:19:47 +02:00
vitaliylag
11735099d6 Update index.js
It was almost bug: imagine args is array but callback is not defined - in this case all args (that is consists of one array) are packing to new array. That mean we get this: this.send_command(command, [[...]]). It doesn't make any sense.

After I fix it we get this: this.send_command(command, [...], undefined). It's really ok because if we call for example client.hget("test", "aaa") we actually do the same: this.send_command("hget", ["test", "aaa"], undefined). No different from this.send_command(command, [...], undefined).

By the way, «this.send_command(command, [[...]])» could be a bug. Try to call client.eval(["return 1", 0]) and you should get throw because "eval" required 2 param, but program thinks it's only one param: ["return 1", 0] (at the beginning it was [["return 1", 0]]). There's only one reason why you don't get throw - RedisClient.prototype.eval is overridden for some optimizations, lucky. But that doesn't mean everything is ok.
2015-05-28 14:50:46 +03:00
Hiroshi Kuwabara
a67d3acdd6 added URL support to createClient 2014-09-12 12:37:32 +09:00
Bryce Baril
75b0bc97ea Fix #645 2014-08-11 10:33:33 -07:00
Jack Tang
064260d1c5 improve the interface to better support unix socket.
delete client.host
delete client.port
add client.address
add client.connectionOptions

add tests.UNIX_SOCKET

update all error message to use client.address
update retry connection
2014-08-07 17:19:37 +08:00
Bryce Baril
2e3cb99011 Merge branch 'master' of https://github.com/migounette/node_redis into migounette-master 2014-07-10 22:01:34 -07:00
Bryce Baril
08a8eed111 Revert "Client to emit errors now instead of throwing them asynchronously where they're uncatchable."
This reverts commit 6a3ccf64f4.
2014-07-10 21:28:48 -07:00
Bryce Baril
8b5d55fecd Set socket_keepalive to default to true 2014-07-10 21:18:47 -07:00
Bryce Baril
b9219a0fb2 Merge branch 'set-keepalive' of https://github.com/Clever/node_redis into Clever-set-keepalive 2014-07-10 21:16:38 -07:00
Bryce Baril
c6ff90723c Merge branch 'master' of https://github.com/ouotuo/node_redis into ouotuo-master 2014-07-10 21:12:37 -07:00
Bryce Baril
782d3333e4 Merge branch 'patch-1' of https://github.com/Raynos/node_redis into Raynos-patch-1 2014-07-10 21:10:17 -07:00
migounette
40f85aa42a Add IPv6 and IPv4 tests 2014-07-09 10:39:08 +02:00
Iain Proctor
c687d2e4fd Make a new stream on reconnect 2014-07-08 23:29:57 +00:00
migounette
9c68a286b1 Add full IPv6 redis connection capability in a full IPv6 network or in a mix network (IPv4 and IPv6) 2014-06-23 16:38:37 +02:00
linkangzhen
c7dbfec85c prototype.end move on("error", to outsite 2014-05-27 09:14:01 +08:00
linkangzhen
1c983a1171 fixed redis quit,we call client.end(),remove "error" event listener,the retry_timer try to connect;when there is a "error" exception,the process will exit 2014-05-27 09:01:28 +08:00
Nick Apperson
b1d8ff9ae8 reply_to_object function is broken for binary keys
There is currently no way to opt out of the way hgetall works with the
node_redis library and if any of the keys have binary, they are
incorrectly converted to the charactor 0xFEFF instead. This makes it
impossible to fully use HGETALL.
2014-05-07 14:14:11 -05:00
Raynos
d34308ea4c check process.domain is STILL currDomain 2014-04-18 13:57:35 -07:00
Raynos (Jake Verbaten)
7d61feb411 Check that process.domain still exists 2014-04-18 13:54:16 -07:00
Mohit Gupta
d313aa5dab param socket_keepalive to set keep-alive on socket 2014-03-25 16:33:43 -07:00