我使用此api- https://github.com/rubenlagus/TelegramBots编写了Java Telegram机器人。我在PC上对其进行了测试,并且效果很好。因此,我决定在Heroku上对其进行测试,但是在工作90秒钟后它崩溃了(前90秒钟运行良好)。Heroku日志:
2018-07-09T08:01:45.000000+00:00 app[api]: Build succeeded
2018-07-09T08:01:46.940201+00:00 heroku[web.1]: Starting process with command `java -Dserver.port=18914 -jar target/AllaBot-1.0.0.jar`
2018-07-09T08:01:49.163121+00:00 app[web.1]: Setting JAVA_TOOL_OPTIONS defaults based on dyno size. Custom settings will override them.
2018-07-09T08:01:49.166682+00:00 app[web.1]: Picked up JAVA_TOOL_OPTIONS: -Xmx300m -Xss512k -Dfile.encoding=UTF-8
2018-07-09T08:03:17.028453+00:00 heroku[web.1]: Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 90 seconds of launch
2018-07-09T08:03:17.028604+00:00 heroku[web.1]: Stopping process with SIGKILL
2018-07-09T08:03:17.121323+00:00 heroku[web.1]: Process exited with status 137
2018-07-09T08:03:17.140915+00:00 heroku[web.1]: State changed from starting to crashed
我的Procfile:
web: java -Dserver.port=$PORT -jar target/AllaBot-1.0.0.jar
据我了解,我需要在项目中更改端口,不是吗?我尝试使用互联网上的一些提示,但它们对我不起作用。
MYYA
喵喵时光机
相关分类