在OPENSHIFT启动Web应用程序时出现503错误

时间:2016-01-28 18:29:22

标签: java spring-mvc openshift web-deployment

我试图从Eclipse在OpenShift上部署Spring MVC应用程序。所有人都成功地推送到OpenShift存储库。但是,当我打开我的网站时,它给了我503错误。我使用的是Spring MVC,Hibernate。 请帮忙! enter image description here

我的日志文件

    Jan 30, 2016 1:23:09 PM org.apache.catalina.startup.Catalina addClusterRuleSet
INFO: Cluster RuleSet not found due to [java.lang.ClassNotFoundException: org.apache.catalina.ha.ClusterRuleSet]. Cluster configuration disabled.
Jan 30, 2016 1:23:09 PM org.apache.catalina.startup.Catalina addClusterRuleSet
INFO: Cluster RuleSet not found due to [java.lang.ClassNotFoundException: org.apache.catalina.ha.ClusterRuleSet]. Cluster configuration disabled.
Jan 30, 2016 1:23:10 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.p$
Jan 30, 2016 1:23:10 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-127.3.60.1-8080"]
Jan 30, 2016 1:23:10 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1499 ms
Jan 30, 2016 1:23:11 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Jan 30, 2016 1:23:11 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.54
Jan 30, 2016 1:23:11 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive /var/lib/openshift/56acfef17628e1c82e00007c/app-root/runtime/dependencies/jbossews/webapps/ROOT.war
Jan 30, 2016 1:23:14 PM org.apache.catalina.util.SessionIdGenerator createSecureRandom
INFO: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [105] milliseconds.
Jan 30, 2016 1:23:14 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deployment of web application archive /var/lib/openshift/56acfef17628e1c82e00007c/app-root/runtime/dependencies/jbossews/webapps/ROOT.war $
Jan 30, 2016 1:23:14 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-127.3.60.1-8080"]
Jan 30, 2016 1:23:14 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 3612 ms
Jan 30, 2016 1:27:04 PM org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["http-bio-127.3.60.1-8080"]
Jan 30, 2016 1:27:04 PM org.apache.catalina.core.StandardService stopInternal
INFO: Stopping service Catalina
Jan 30, 2016 1:27:04 PM org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["http-bio-127.3.60.1-8080"]
Jan 30, 2016 1:27:04 PM org.apache.coyote.AbstractProtocol destroy
INFO: Destroying ProtocolHandler ["http-bio-127.3.60.1-8080"]
Jan 30, 2016 1:58:25 PM org.apache.catalina.startup.Catalina addClusterRuleSet
INFO: Cluster RuleSet not found due to [java.lang.ClassNotFoundException: org.apache.catalina.ha.ClusterRuleSet]. Cluster configuration disabled.
Jan 30, 2016 1:58:26 PM org.apache.catalina.startup.Catalina addClusterRuleSet
INFO: Cluster RuleSet not found due to [java.lang.ClassNotFoundException: org.apache.catalina.ha.ClusterRuleSet]. Cluster configuration disabled.

1 个答案:

答案 0 :(得分:0)

我使用的是:Spring MVC,Hibernate。

我在某些步骤中解决了这个问题:

  1. 在OpenShift创建“空”应用程序
  2. 将其克隆到本地存储库
  3. 从您在OpenShift的本地存储库中克隆的项目中删除 src 文件夹和 pom.xml 文件
  4. 创建需要部署的项目的 .war 文件。
  5. 将此 .war 文件复制到 project_name / webapps 文件夹中的克隆项目。
  6. 毕竟,提交并将其推送到OpenShift repo。
  7. 使用 yourAppName-yourDomain.rhcloud.com/yourWarFileName
  8. 等网址在OpenShift上打开您的网络应用

    很高兴我会帮助smbd!