/** * Cache Module * * Provides Redis cache adapter as CachePort implementation */ import { Module, Global } from '@nestjs/common'; import { RedisCacheAdapter } from './redis-cache.adapter'; @Global() @Module({ providers: [ { provide: 'CachePort', useClass: RedisCacheAdapter, }, RedisCacheAdapter, ], exports: ['CachePort', RedisCacheAdapter], }) export class CacheModule {}