|
|
@@ -311,14 +311,16 @@ export class HomepageService {
|
|
|
|
|
|
async getCategoryTags(channelId: string): Promise<any[]> {
|
|
|
try {
|
|
|
+ this.logger.log(`Cache miss for category tags of channelId=${channelId}`);
|
|
|
const cacheKey = `category:tag:${channelId}`;
|
|
|
const cache = await this.redis.getJson<HomeCategoryCacheItem[]>(cacheKey);
|
|
|
if (cache) {
|
|
|
+ this.logger.log(
|
|
|
+ `Cache hit for category tags of channelId=${channelId}`,
|
|
|
+ );
|
|
|
return cache;
|
|
|
}
|
|
|
|
|
|
- this.logger.log(`Cache miss for category tags of channelId=${channelId}`);
|
|
|
-
|
|
|
const channel = await this.prisma.channel.findUnique({
|
|
|
where: { channelId },
|
|
|
// select: {
|