node.js - 有时 pm2 不输出时间戳

标签 node.js pm2

我的 Node 模块使用 pm2 的 --log-date-format 选项在输出 console.log 时包含时间戳。顺便说一下, Node 模块的日志中有时可能会丢失时间戳。

例如,

2018-03-01 17:04:02 hello 1
2018-03-01 17:04:02 hello 2
hello 3
2018-03-01 17:04:03 hello 4

如何解决这个问题?这是因为pm2还不成熟吗?

谢谢。

最佳答案

也许这就是那个问题?

https://github.com/Unitech/pm2/issues/183

但是,这个问题还没有完全解决,但现在已经关闭了。在评论中 pm2 有时会出现 --log-date-format

问题

关于node.js - 有时 pm2 不输出时间戳,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49045198/

相关文章:

javascript - 如何在node js中下载服务器文件?

mysql - 使用 NodeJS 插入 MySQL 日期

angularjs - 在 View 中看不到我的 html 文件

node.js - Node.js +express +socket.io +pm2 能否完全替代 Nginx 处理大并发请求?

linux - 在没有互联网访问的情况下安装 unix 程序

javascript - 从 Node.js 函数返回值的正确方法

node.js - Node : Cannot find module common

python - 使用 pm2 运行 gunicorn 和 flask 无法正确加载 css

node.js - PM2端口号 express app

node.js - 如果从 gulp 启动,则使用 pm2 启动应用程序