Skip to content

Commit 318e38f

Browse files
committed
refactor(dbrunner): Rename to cache.dbrunner
Match what others have named.
1 parent 4613932 commit 318e38f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

config/packages/cache.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ framework:
66
default_redis_provider: "%app.redis_uri%"
77

88
pools:
9-
app.dbrunner.cache:
9+
cache.dbrunner:
1010
adapter: cache.adapter.redis_tag_aware
1111
default_lifetime: "12 hour"
1212
# Unique name of your app: used to compute stable namespaces for cache keys.

src/Service/DbRunnerService.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
{
1414
protected DbRunner $dbRunner;
1515

16-
public function __construct(protected CacheInterface $appDbrunnerCache)
16+
public function __construct(protected CacheInterface $cacheDbrunner)
1717
{
1818
$this->dbRunner = new DbRunner();
1919
}
@@ -33,6 +33,6 @@ public function runQuery(string $schema, string $query): array
3333
$queryHash = $this->dbRunner->hashStatement($query);
3434
$hash = "dbrunner.$schemaHash.$queryHash";
3535

36-
return $this->appDbrunnerCache->get($hash, fn () => $this->dbRunner->runQuery($schema, $query));
36+
return $this->cacheDbrunner->get($hash, fn () => $this->dbRunner->runQuery($schema, $query));
3737
}
3838
}

0 commit comments

Comments
 (0)