简体   繁体   中英

Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 90 seconds of launch java

I upload the .jar file of my bot for discord to heroku. Everything works as it should. And then the app breaks down and everything stops working.

Application Logs

heroku[web.1]: Starting process with command `java $JAVA_OPTS -jar target/DiscordBot-1.0-SNAPSHOT-jar-with-dependencies.jar -Dserver.port=43997`
app[web.1]: Setting JAVA_TOOL_OPTIONS defaults based on dyno size. Custom settings will override them.
app[web.1]: Picked up JAVA_TOOL_OPTIONS: -Xmx300m -Xss512k -XX:CICompilerCount=2 -Dfile.encoding=UTF-8 
app[web.1]: [main] INFO net.dv8tion.jda.api.JDA - Login Successful!
app[web.1]: [JDA MainWS-ReadThread] INFO net.dv8tion.jda.internal.requests.WebSocketClient - Connected to WebSocket
app[web.1]: [JDA MainWS-ReadThread] INFO net.dv8tion.jda.api.JDA - Finished Loading!
heroku[web.1]: Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 90 seconds of launch
heroku[web.1]: Stopping process with SIGKILL
heroku[web.1]: Process exited with status 137

Procfile

web: java $JAVA_OPTS -jar target/DiscordBot-1.0-SNAPSHOT-jar-with-dependencies.jar -Dserver.port=$PORT

application.properties

server.port=${PORT:8080}

worker: java -jar target/DiscordBot-1.0-SNAPSHOT-jar-with-dependencies.jar

without server.port=${PORT:8080} in application.properties

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM