java – 错误R10(引导超时) – > Web进程在启动后60秒内无法
发布时间:2020-12-15 02:05:39 所属栏目:Java 来源:网络整理
导读:我正在尝试在heroku上部署我的服务器.我收到了这个错误: Error R10 (Boot timeout) - Web process failed to bind to $PORT within 60 seconds of launch 这是我的Java类: package introsde.document.endpoint;import javax.xml.ws.Endpoint;import intros
我正在尝试在heroku上部署我的服务器.我收到了这个错误:
Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch 这是我的Java类: package introsde.document.endpoint; import javax.xml.ws.Endpoint; import introsde.assignment.soap.PeopleImpl; public class PeoplePublisher { public static String SERVER_URL = "http://localhost"; public static String PORT = "6902"; public static String BASE_URL = "/ws/people"; public static String getEndpointURL() { return SERVER_URL+":"+PORT+BASE_URL; } public static void main(String[] args) { String endpointUrl = getEndpointURL(); System.out.println("Starting People Service..."); System.out.println("--> Published at = "+endpointUrl); Endpoint.publish(endpointUrl,new PeopleImpl()); } } 我怎么解决这个问题? 谢谢 解决方法
尝试创建一个最小的spring-boot应用程序时遇到了同样的问题.我已经将heroku的java-getting-started实现与我的比较,并找到了这个很好的修复.
只需将其添加到src / main / resources / application.properties即可 server.port=${PORT:5000} (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |