260320:1210 Refactor Overrall #06 failed to start due to missing CACHE_MANAGER dependency.
Build and Deploy / deploy (push) Successful in 10m42s
Build and Deploy / deploy (push) Successful in 10m42s
This commit is contained in:
@@ -10,6 +10,7 @@ import { TypeOrmModule } from '@nestjs/typeorm';
|
|||||||
import { BullModule } from '@nestjs/bullmq';
|
import { BullModule } from '@nestjs/bullmq';
|
||||||
import { ThrottlerModule, ThrottlerGuard } from '@nestjs/throttler';
|
import { ThrottlerModule, ThrottlerGuard } from '@nestjs/throttler';
|
||||||
import { WinstonModule } from 'nest-winston';
|
import { WinstonModule } from 'nest-winston';
|
||||||
|
import { CacheModule } from '@nestjs/cache-manager';
|
||||||
// Redis store will be imported dynamically in the factory
|
// Redis store will be imported dynamically in the factory
|
||||||
import { RedisModule } from '@nestjs-modules/ioredis';
|
import { RedisModule } from '@nestjs-modules/ioredis';
|
||||||
|
|
||||||
@@ -93,6 +94,12 @@ import { MigrationModule } from './modules/migration/migration.module';
|
|||||||
}),
|
}),
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
// 🔄 Temporary Cache Module (In-Memory) for build fixes
|
||||||
|
CacheModule.register({
|
||||||
|
isGlobal: true, // Make available globally for all modules
|
||||||
|
ttl: 300, // 5 minutes default TTL
|
||||||
|
}),
|
||||||
|
|
||||||
// 📝 Setup Winston Logger
|
// 📝 Setup Winston Logger
|
||||||
WinstonModule.forRoot(winstonConfig),
|
WinstonModule.forRoot(winstonConfig),
|
||||||
|
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ import type { StringValue } from 'ms';
|
|||||||
TypeOrmModule.forFeature([User, RefreshToken]), // [P2-2] Added RefreshToken
|
TypeOrmModule.forFeature([User, RefreshToken]), // [P2-2] Added RefreshToken
|
||||||
UserModule,
|
UserModule,
|
||||||
PassportModule,
|
PassportModule,
|
||||||
|
// CacheModule is now global (from AppModule)
|
||||||
JwtModule.registerAsync({
|
JwtModule.registerAsync({
|
||||||
imports: [ConfigModule],
|
imports: [ConfigModule],
|
||||||
inject: [ConfigService],
|
inject: [ConfigService],
|
||||||
|
|||||||
@@ -3,7 +3,6 @@
|
|||||||
|
|
||||||
import { Module } from '@nestjs/common';
|
import { Module } from '@nestjs/common';
|
||||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||||
import { CacheModule } from '@nestjs/cache-manager';
|
|
||||||
|
|
||||||
import { UserService } from './user.service';
|
import { UserService } from './user.service';
|
||||||
import { UserController } from './user.controller';
|
import { UserController } from './user.controller';
|
||||||
@@ -27,10 +26,7 @@ import { Permission } from './entities/permission.entity';
|
|||||||
Role,
|
Role,
|
||||||
Permission,
|
Permission,
|
||||||
]),
|
]),
|
||||||
// Add CacheModule for CACHE_MANAGER provider
|
// CacheModule is now global (from AppModule)
|
||||||
CacheModule.register({
|
|
||||||
isGlobal: false, // Keep it local to this module
|
|
||||||
}),
|
|
||||||
],
|
],
|
||||||
controllers: [UserController],
|
controllers: [UserController],
|
||||||
providers: [
|
providers: [
|
||||||
|
|||||||
Reference in New Issue
Block a user