File tree Expand file tree Collapse file tree 3 files changed +6
-111
lines changed
Expand file tree Collapse file tree 3 files changed +6
-111
lines changed Original file line number Diff line number Diff line change @@ -151,7 +151,7 @@ export class BaileysStartupService extends WAStartupService {
151151 const cacheConf = this . configService . get < CacheConf > ( 'CACHE' ) ;
152152
153153 if ( ( cacheConf ?. REDIS ?. ENABLED && cacheConf ?. REDIS ?. URI !== '' ) || cacheConf ?. LOCAL ?. ENABLED ) {
154- setTimeout ( async ( ) => {
154+ setInterval ( async ( ) => {
155155 this . logger . info ( 'Recovering messages' ) ;
156156 this . messagesLostCache . keys ( ) . then ( ( keys ) => {
157157 keys . forEach ( async ( key ) => {
Original file line number Diff line number Diff line change 11import { ICache } from '../api/abstract/abstract.cache' ;
22import { CacheConf , ConfigService } from '../config/env.config' ;
3+ import { Logger } from '../config/logger.config' ;
34import { LocalCache } from './localcache' ;
45import { RedisCache } from './rediscache' ;
56
7+ const logger = new Logger ( 'Redis' ) ;
8+
69export class CacheEngine {
710 private engine : ICache ;
811
@@ -14,6 +17,8 @@ export class CacheEngine {
1417 } else if ( cacheConf ?. LOCAL ?. ENABLED ) {
1518 this . engine = new LocalCache ( configService , module ) ;
1619 }
20+
21+ logger . info ( `RedisCache initialized for ${ module } ` ) ;
1722 }
1823
1924 public getEngine ( ) {
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments