nestjs / typeorm

TypeORM module for Nest framework (node.js) 🍇

Home Page:https://nestjs.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

When application startup but database is stopped, TypeOrmModule throw exception after retry 10 times

keito99 opened this issue · comments

I'm submitting a...


[ ] Regression 
[x] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead post your question on Stack Overflow.

Current behavior

When my application startup, TypeOrmModule throw exception after 10 reties and my application shutdown.
In my application, I use TypeOrmModule to store archive data into db occasionally. So the connection is not essential to my application startup. I expect the application can still running event database is not available when application startup.

Expected behavior

Expecting TypeOrmModule can start up successfully even when database is stopped.

Minimal reproduction of the problem with instructions

What is the motivation / use case for changing the behavior?

Environment


Nest version: 7.0.0
 
For Tooling issues:
- Node version: 12.16.1
- Platform:  Linux

Others:

I'm not sure whether this is related, but I'm currently investigating a similar issue: my NestJS application no longer starts due to sudden timeout issues with our DigitalOcean hosted database. In fact, it does not initialize the TypeOrmCoreModule, which suggests connectivity issues.