Skip to content

Commit c12c8b6

Browse files
simplify things
1 parent ca7fce1 commit c12c8b6

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

lib/util.ts

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,6 @@ function mapResult(result) {
5757
};
5858
}
5959

60-
const POOL = Symbol("redis-v5-pool");
61-
6260
/**
6361
* @see https://redis.io/commands/xread/
6462
*/
@@ -70,28 +68,6 @@ export function XREAD(
7068
blockTimeInMs: number
7169
) {
7270
if (isNodeRedisClient(redisClient)) {
73-
if (typeof redisClient.createPool === "function") {
74-
if (!redisClient[POOL]) {
75-
redisClient[POOL] = redisClient.createPool();
76-
77-
redisClient.on("end", () => {
78-
redisClient[POOL].destroy();
79-
});
80-
}
81-
82-
return redisClient[POOL].xRead(
83-
[
84-
{
85-
key: streamName,
86-
id: offset,
87-
},
88-
],
89-
{
90-
COUNT: readCount,
91-
BLOCK: blockTimeInMs,
92-
}
93-
);
94-
}
9571
return redisClient.xRead(
9672
[
9773
{

0 commit comments

Comments
 (0)