我正在使用Python和Flask创建一个API,并在本地运行它 MyApp.run() ,它似乎按计划运行 .

当我将其部署到我的Web托管服务提供商时,我看到了相同类型的日志输出,但我也看到启动日志消息多次出现 . 例如,启动时出现以下内容:

[2018-12-10 09:17:39,587] INFO [root.setup_logging:12] Started logging with config/logging.cfg and debugging: True
[2018-12-10 09:17:40,238] INFO [api.create_app:116] Started production app src.api

我在部署的版本中看到的是我在本地看不到的是几个创业公司的以下几种情况(有时是交织在一起,有时不是):

[2018-12-10 09:17:39,587] INFO [root.setup_logging:12] Started logging with config/logging.cfg and debugging: True
[2018-12-10 09:17:40,238] INFO [api.create_app:116] Started production app src.api
... (assume normal INFO messages here)
[2018-12-10 09:57:39,844] INFO [root.setup_logging:12] Started logging with config/logging.cfg and debugging: True
[2018-12-10 09:57:39,906] INFO [util.days:89] 2018-12-29 is not a working day
[2018-12-10 09:57:39,908] INFO [util.days:89] 2018-12-30 is not a working day
[2018-12-10 09:57:39,909] INFO [util.days:89] 2018-12-31 is not a working day
[2018-12-10 09:57:39,911] INFO [util.days:89] 2019-01-01 is not a working day
[2018-12-10 09:57:40,457] INFO [api.create_app:116] Started production app src.api

我担心的是,我在某种程度上错过了一些导致Passenger突然重启的错误输出,或者错过了某种可能会让我感到困惑的“多次启动”场景 .

我错过了导致此错误的错误吗? Can Passenger可以故意启动我的Flask应用程序的多个实例吗?这不会导致对象实例f.x出现问题 . 与SQLAlchemy有关?