heroku请求超时503

unhi4e5o  于 2023-02-13  发布在  其他
关注(0)|答案(1)|浏览(113)

我最近向heroku发起了一个nodejs项目,构建非常成功。在我的nodejs的默认页面或初始页面上显示了一条消息“hello this is backend”,这是我设置的消息。当我尝试发出请求时,它开始无故超时。我怀疑这是mongodb网络访问问题,我将网络访问设置为每个人,仍然在同一个地方。这是我的构建日志,我得到当我提出请求。任何帮助是非常感谢。

2023-02-07T07:00:12.397821+00:00 app[web.1]: [0mGET /api/blogs/posts [0m-[0m - ms - -[0m
2023-02-07T07:00:12.400365+00:00 heroku[router]: at=error code=H12 desc="Request timeout" method=GET path="/api/blogs/posts" host=blog-backend-0.herokuapp.com request_id=c42937a8-a290-4393-89a6-3e82dc382a3b fwd="96.2.91.62" dyno=web.1 connect=0ms service=30000ms status=503 bytes=0 protocol=https
2023-02-07T07:08:02.319730+00:00 heroku[router]: at=info method=GET path="/api/blogs/posts/63bb5739b3df321e78e219e0" host=blog-backend-0.herokuapp.com request_id=523b9b8b-8a02-4009-b2ed-1855dceca104 fwd="96.2.91.62" dyno=web.1 connect=0ms service=10005ms status=304 bytes=940 protocol=https
2023-02-07T07:08:02.320404+00:00 app[web.1]: [0mGET /api/blogs/posts/63bb5739b3df321e78e219e0 [36m304[0m 10004.226 ms - -[0m
2023-02-07T23:19:39.802708+00:00 heroku[router]: at=info method=GET path="/favicon.ico" host=blog-backend-0.herokuapp.com request_id=f7841a6a-7135-42c5-ad4a-4991b9749b1b fwd="96.2.91.62" dyno=web.1 connect=0ms service=44ms status=404 bytes=873 protocol=https
2023-02-07T23:19:39.804862+00:00 app[web.1]: [0mGET /favicon.ico [33m404[0m 3.861 ms - 150[0m
2023-02-07T23:20:02.518798+00:00 heroku[router]: at=info method=GET path="/api/blogs/posts/63bb5739b3df321e78e219e0" host=blog-backend-0.herokuapp.com request_id=69f2f554-17ac-46f8-aad4-2698a666ef12 fwd="96.2.91.62" dyno=web.1 connect=0ms service=10038ms status=304 bytes=940 protocol=https
2023-02-07T23:20:02.519517+00:00 app[web.1]: [0mGET /api/blogs/posts/63bb5739b3df321e78e219e0 [36m304[0m 10034.051 ms - -[0m
2023-02-07T23:20:27.580101+00:00 heroku[router]: at=error code=H12 desc="Request timeout" method=GET path="/api/blogs/posts/" host=blog-backend-0.herokuapp.com request_id=7e7fe49d-5a23-4f34-ab67-7ac0dc46516e fwd="96.2.91.62" dyno=web.1 connect=0ms service=30000ms status=503 bytes=0 protocol=https
2023-02-07T23:20:27.584117+00:00 app[web.1]: [0mGET /api/blogs/posts/ [0m-[0m - ms - -[0m
9cbw7uwe

9cbw7uwe1#

问题是我没有从.gitignore中取出.env文件,所以它永远无法访问端口号或mongoDB字符串。

相关问题