@redis/client
Advanced tools
Comparing version 1.5.8 to 1.5.9
@@ -174,3 +174,2 @@ "use strict"; | ||
} | ||
exports.default = RedisCommandsQueue; | ||
_a = RedisCommandsQueue, _RedisCommandsQueue_maxLength = new WeakMap(), _RedisCommandsQueue_waitingToBeSent = new WeakMap(), _RedisCommandsQueue_waitingForReply = new WeakMap(), _RedisCommandsQueue_onShardedChannelMoved = new WeakMap(), _RedisCommandsQueue_pubSub = new WeakMap(), _RedisCommandsQueue_chainInExecution = new WeakMap(), _RedisCommandsQueue_decoder = new WeakMap(), _RedisCommandsQueue_instances = new WeakSet(), _RedisCommandsQueue_flushQueue = function _RedisCommandsQueue_flushQueue(queue, err) { | ||
@@ -199,1 +198,2 @@ while (queue.length) { | ||
}; | ||
exports.default = RedisCommandsQueue; |
@@ -259,2 +259,4 @@ "use strict"; | ||
return __classPrivateFieldGet(this, _RedisClient_socket, "f").quit(async () => { | ||
if (__classPrivateFieldGet(this, _RedisClient_pingTimer, "f")) | ||
clearTimeout(__classPrivateFieldGet(this, _RedisClient_pingTimer, "f")); | ||
const quitPromise = __classPrivateFieldGet(this, _RedisClient_queue, "f").addCommand(['QUIT']); | ||
@@ -337,2 +339,4 @@ __classPrivateFieldGet(this, _RedisClient_instances, "m", _RedisClient_tick).call(this); | ||
async disconnect() { | ||
if (__classPrivateFieldGet(this, _RedisClient_pingTimer, "f")) | ||
clearTimeout(__classPrivateFieldGet(this, _RedisClient_pingTimer, "f")); | ||
__classPrivateFieldGet(this, _RedisClient_queue, "f").flushAll(new errors_1.DisconnectsClientError()); | ||
@@ -349,3 +353,2 @@ __classPrivateFieldGet(this, _RedisClient_socket, "f").disconnect(); | ||
} | ||
exports.default = RedisClient; | ||
_RedisClient_options = new WeakMap(), _RedisClient_socket = new WeakMap(), _RedisClient_queue = new WeakMap(), _RedisClient_isolationPool = new WeakMap(), _RedisClient_v4 = new WeakMap(), _RedisClient_selectedDB = new WeakMap(), _RedisClient_pingTimer = new WeakMap(), _RedisClient_instances = new WeakSet(), _RedisClient_initiateOptions = function _RedisClient_initiateOptions(options) { | ||
@@ -530,2 +533,3 @@ if (options?.url) { | ||
}; | ||
exports.default = RedisClient; | ||
(0, commander_1.attachCommands)({ | ||
@@ -532,0 +536,0 @@ BaseClass: RedisClient, |
@@ -89,3 +89,2 @@ "use strict"; | ||
} | ||
exports.default = RedisClientMultiCommand; | ||
_RedisClientMultiCommand_multi = new WeakMap(), _RedisClientMultiCommand_executor = new WeakMap(), _RedisClientMultiCommand_selectedDB = new WeakMap(), _RedisClientMultiCommand_instances = new WeakSet(), _RedisClientMultiCommand_legacyMode = function _RedisClientMultiCommand_legacyMode() { | ||
@@ -127,2 +126,3 @@ var _a, _b; | ||
}; | ||
exports.default = RedisClientMultiCommand; | ||
(0, commander_1.attachCommands)({ | ||
@@ -129,0 +129,0 @@ BaseClass: RedisClientMultiCommand, |
@@ -21,3 +21,3 @@ "use strict"; | ||
PubSubType["SHARDED"] = "SHARDED"; | ||
})(PubSubType = exports.PubSubType || (exports.PubSubType = {})); | ||
})(PubSubType || (exports.PubSubType = PubSubType = {})); | ||
const COMMANDS = { | ||
@@ -24,0 +24,0 @@ [PubSubType.CHANNELS]: { |
@@ -97,3 +97,2 @@ "use strict"; | ||
} | ||
exports.default = RedisSocket; | ||
_a = RedisSocket, _RedisSocket_initiator = new WeakMap(), _RedisSocket_options = new WeakMap(), _RedisSocket_socket = new WeakMap(), _RedisSocket_isOpen = new WeakMap(), _RedisSocket_isReady = new WeakMap(), _RedisSocket_writableNeedDrain = new WeakMap(), _RedisSocket_isSocketUnrefed = new WeakMap(), _RedisSocket_isCorked = new WeakMap(), _RedisSocket_instances = new WeakSet(), _RedisSocket_initiateOptions = function _RedisSocket_initiateOptions(options) { | ||
@@ -234,1 +233,2 @@ var _b, _c; | ||
}; | ||
exports.default = RedisSocket; |
@@ -215,3 +215,2 @@ "use strict"; | ||
} | ||
exports.default = RedisCluster; | ||
_RedisCluster_options = new WeakMap(), _RedisCluster_slots = new WeakMap(), _RedisCluster_Multi = new WeakMap(), _RedisCluster_instances = new WeakSet(), _RedisCluster_execute = async function _RedisCluster_execute(firstKey, isReadonly, executor) { | ||
@@ -251,2 +250,3 @@ const maxCommandRedirections = __classPrivateFieldGet(this, _RedisCluster_options, "f").maxCommandRedirections ?? 16; | ||
}; | ||
exports.default = RedisCluster; | ||
(0, commander_1.attachCommands)({ | ||
@@ -253,0 +253,0 @@ BaseClass: RedisCluster, |
@@ -74,4 +74,4 @@ "use strict"; | ||
} | ||
_RedisClusterMultiCommand_multi = new WeakMap(), _RedisClusterMultiCommand_executor = new WeakMap(), _RedisClusterMultiCommand_firstKey = new WeakMap(); | ||
exports.default = RedisClusterMultiCommand; | ||
_RedisClusterMultiCommand_multi = new WeakMap(), _RedisClusterMultiCommand_executor = new WeakMap(), _RedisClusterMultiCommand_firstKey = new WeakMap(); | ||
(0, commander_1.attachCommands)({ | ||
@@ -78,0 +78,0 @@ BaseClass: RedisClusterMultiCommand, |
@@ -12,3 +12,3 @@ "use strict"; | ||
ClientKillFilters["SKIP_ME"] = "SKIPME"; | ||
})(ClientKillFilters = exports.ClientKillFilters || (exports.ClientKillFilters = {})); | ||
})(ClientKillFilters || (exports.ClientKillFilters = ClientKillFilters = {})); | ||
function transformArguments(filters) { | ||
@@ -15,0 +15,0 @@ const args = ['CLIENT', 'KILL']; |
@@ -8,3 +8,3 @@ "use strict"; | ||
FailoverModes["TAKEOVER"] = "TAKEOVER"; | ||
})(FailoverModes = exports.FailoverModes || (exports.FailoverModes = {})); | ||
})(FailoverModes || (exports.FailoverModes = FailoverModes = {})); | ||
function transformArguments(mode) { | ||
@@ -11,0 +11,0 @@ const args = ['CLUSTER', 'FAILOVER']; |
@@ -12,3 +12,3 @@ "use strict"; | ||
RedisClusterNodeLinkStates["DISCONNECTED"] = "disconnected"; | ||
})(RedisClusterNodeLinkStates = exports.RedisClusterNodeLinkStates || (exports.RedisClusterNodeLinkStates = {})); | ||
})(RedisClusterNodeLinkStates || (exports.RedisClusterNodeLinkStates = RedisClusterNodeLinkStates = {})); | ||
function transformReply(reply) { | ||
@@ -15,0 +15,0 @@ const lines = reply.split('\n'); |
@@ -10,3 +10,3 @@ "use strict"; | ||
ClusterSlotStates["NODE"] = "NODE"; | ||
})(ClusterSlotStates = exports.ClusterSlotStates || (exports.ClusterSlotStates = {})); | ||
})(ClusterSlotStates || (exports.ClusterSlotStates = ClusterSlotStates = {})); | ||
function transformArguments(slot, state, nodeId) { | ||
@@ -13,0 +13,0 @@ const args = ['CLUSTER', 'SETSLOT', slot.toString(), state]; |
@@ -10,3 +10,3 @@ "use strict"; | ||
FilterBy["PATTERN"] = "PATTERN"; | ||
})(FilterBy = exports.FilterBy || (exports.FilterBy = {})); | ||
})(FilterBy || (exports.FilterBy = FilterBy = {})); | ||
function transformArguments(filter) { | ||
@@ -13,0 +13,0 @@ const args = ['COMMAND', 'LIST']; |
@@ -8,3 +8,3 @@ "use strict"; | ||
RedisFlushModes["SYNC"] = "SYNC"; | ||
})(RedisFlushModes = exports.RedisFlushModes || (exports.RedisFlushModes = {})); | ||
})(RedisFlushModes || (exports.RedisFlushModes = RedisFlushModes = {})); | ||
function transformArguments(mode) { | ||
@@ -11,0 +11,0 @@ const args = ['FLUSHALL']; |
@@ -198,3 +198,3 @@ "use strict"; | ||
GeoReplyWith["COORDINATES"] = "WITHCOORD"; | ||
})(GeoReplyWith = exports.GeoReplyWith || (exports.GeoReplyWith = {})); | ||
})(GeoReplyWith || (exports.GeoReplyWith = GeoReplyWith = {})); | ||
function transformGeoMembersWithReply(reply, replyWith) { | ||
@@ -306,3 +306,3 @@ const replyWithSet = new Set(replyWith); | ||
CommandFlags["MOVABLEKEYS"] = "movablekeys"; // keys have no pre-determined position. You must discover keys yourself. | ||
})(CommandFlags = exports.CommandFlags || (exports.CommandFlags = {})); | ||
})(CommandFlags || (exports.CommandFlags = CommandFlags = {})); | ||
var CommandCategories; | ||
@@ -331,3 +331,3 @@ (function (CommandCategories) { | ||
CommandCategories["SCRIPTING"] = "@scripting"; | ||
})(CommandCategories = exports.CommandCategories || (exports.CommandCategories = {})); | ||
})(CommandCategories || (exports.CommandCategories = CommandCategories = {})); | ||
function transformCommandReply([name, arity, flags, firstKeyIndex, lastKeyIndex, step, categories]) { | ||
@@ -351,3 +351,3 @@ return { | ||
RedisFunctionFlags["NO_CLUSTER"] = "no-cluster"; | ||
})(RedisFunctionFlags = exports.RedisFunctionFlags || (exports.RedisFunctionFlags = {})); | ||
})(RedisFunctionFlags || (exports.RedisFunctionFlags = RedisFunctionFlags = {})); | ||
function transformFunctionListItemReply(reply) { | ||
@@ -354,0 +354,0 @@ return { |
{ | ||
"name": "@redis/client", | ||
"version": "1.5.8", | ||
"version": "1.5.9", | ||
"license": "MIT", | ||
@@ -24,15 +24,15 @@ "main": "./dist/index.js", | ||
"@redis/test-utils": "*", | ||
"@types/node": "^20.2.3", | ||
"@types/sinon": "^10.0.15", | ||
"@types/node": "^20.5.3", | ||
"@types/sinon": "^10.0.16", | ||
"@types/yallist": "^4.0.1", | ||
"@typescript-eslint/eslint-plugin": "^5.59.7", | ||
"@typescript-eslint/parser": "^5.59.7", | ||
"eslint": "^8.41.0", | ||
"@typescript-eslint/eslint-plugin": "^6.4.1", | ||
"@typescript-eslint/parser": "^6.4.1", | ||
"eslint": "^8.47.0", | ||
"nyc": "^15.1.0", | ||
"release-it": "^15.10.3", | ||
"sinon": "^15.1.0", | ||
"release-it": "^16.1.5", | ||
"sinon": "^15.2.0", | ||
"source-map-support": "^0.5.21", | ||
"ts-node": "^10.9.1", | ||
"typedoc": "^0.24.7", | ||
"typescript": "^5.0.4" | ||
"typedoc": "^0.24.8", | ||
"typescript": "^5.1.6" | ||
}, | ||
@@ -39,0 +39,0 @@ "engines": { |
587848
13096