@@ -198,7 +198,7 @@ |
||
198 | 198 | $async_connection = $this->redis->getNativeRedisConnection($this->option('connection_name'), $this->option('host'), $this->option('port')); |
199 | 199 | $pattern = '__keyevent@' . $async_connection['database'] . '__:expired'; |
200 | 200 | // La psubscribe è BLOCCANTE, il command resta attivo finchè non cade la connessione |
201 | - $async_connection['connection']->psubscribe([$pattern], function ($redis, $channel, $message, $key) { |
|
201 | + $async_connection['connection']->psubscribe([$pattern], function($redis, $channel, $message, $key) { |
|
202 | 202 | $this->onExpireEvent($key); |
203 | 203 | |
204 | 204 | // Verifica se è necessario processare il batch |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | // Usa pipeline solo se non è un cluster |
87 | 87 | $isCluster = config('database.redis.clusters.' . ($connection_name ?? 'default')) !== null; |
88 | 88 | if (!$isCluster) { |
89 | - $this->redis->pipeline(function ($pipe) use ($finalKey, $finalTags, $value, $tags, $ttl) { |
|
89 | + $this->redis->pipeline(function($pipe) use ($finalKey, $finalTags, $value, $tags, $ttl) { |
|
90 | 90 | // Qui devo mettere le {} perchè così mi assicuro che la chiave e i suoi tags stiano nello stesso has |
91 | 91 | if ($ttl !== null) { |
92 | 92 | $pipe->setEx($finalKey, $ttl, $this->serializeForRedis($value)); |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | $tags = $this->redis->getRedisConnection($connection_name)->smembers($finalTags); |
177 | 177 | $isCluster = config('database.redis.clusters.' . ($connection_name ?? 'default')) !== null; |
178 | 178 | if (!$isCluster) { |
179 | - $this->redis->pipeline(function ($pipe) use ($isWithTags, $onlyTags, $tags, $finalKey, $finalTags) { |
|
179 | + $this->redis->pipeline(function($pipe) use ($isWithTags, $onlyTags, $tags, $finalKey, $finalTags) { |
|
180 | 180 | foreach ($tags as $tag) { |
181 | 181 | $shard = $this->getShardNameForTag($tag, $finalKey); |
182 | 182 | $pipe->srem($shard, $finalKey); |