0

i'm trying to use "Nestjs/Bull" and using addon "Heroku Data for Redis" as its redis in Deployed Heroku App.

But it's seems failed to connect, there is no job queued and executed.

Here's my bull config in app.module.ts :

imports: [
 BullModule.forRootAsync({ useClass: ConfigBull }),
]

Here's ConfigBull Class:

@Injectable()
export class ConfigBull implements SharedBullConfigurationFactory {
  constructor(private configService: ConfigService) {}

  createSharedConfiguration(): BullModuleOptions {

   return {
            url: this.configService.get(ConfigServiceCache.CACHE_URL), //# Here i Input rediss url
          };
  }
}

After i add job queue, redis was ready but there is no job queued or executed and returned timeout.

Here is my heroku dyno scale: heroku ps:scale web=2 worker=1

I already tried a solution based on Why is @nestjs/bull not able to connect to Heroku Redis?, but it doesn't work for me.

TowewTew
  • 1
  • 1

1 Answers1

0

try register Bull with redis url in app module:

BullModule.forRoot({
      url: <Redis URL From Heroku>,
}),
Moritz Ringler
  • 9,772
  • 9
  • 21
  • 34