WildFly 10.x总是收到HTTP错误403:禁止

时间:2017-01-11 09:13:48

标签: java eclipse jboss jsf-2.2 wildfly-10

我开始了解JSF,因此我尝试运行一个hello world xhtml网站。问题:在浏览器中访问站点时,我总是收到HTTP错误代码403:禁止。

我正在使用eclipse neon和WildFly Server v10。我在eclipse中使用JBoss Tools插件进行部署。我总是使用默认配置。服务器的日志不显示任何错误,应正确部署站点:

09:50:23,999 INFO  [org.jboss.ws.common.management] (MSC service thread 1-6) JBWS022052: Starting JBossWS 5.1.5.Final (Apache CXF 3.1.6) 
09:50:24,297 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-4) WFLYJCA0005: Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)
09:50:24,299 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-4) WFLYJCA0005: Deploying non-JDBC-compliant driver class com.mysql.fabric.jdbc.FabricMySQLDriver (version 5.1)
09:50:24,315 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-7) WFLYJCA0018: Started Driver service with driver-name = mysql-connector-java-5.1.40-bin.jar_com.mysql.jdbc.Driver_5_1
09:50:24,315 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-2) WFLYJCA0018: Started Driver service with driver-name = mysql-connector-java-5.1.40-bin.jar_com.mysql.fabric.jdbc.FabricMySQLDriver_5_1
09:50:24,318 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-6) WFLYJCA0001: Bound data source [java:jboss/datasources/university]
09:50:24,551 INFO  [javax.enterprise.resource.webcontainer.jsf.config] (ServerService Thread Pool -- 60) Mojarra 2.2.13.SP1 20160303-1204 für Kontext '/HelloWorldJSF' wird initialisiert.
09:50:24,551 INFO  [javax.enterprise.resource.webcontainer.jsf.config] (ServerService Thread Pool -- 65) Mojarra 2.2.13.SP1 20160303-1204 für Kontext '/HelloWorld' wird initialisiert.
09:50:25,034 INFO  [org.wildfly.extension.undertow] (ServerService Thread Pool -- 60) WFLYUT0021: Registered web context: /HelloWorldJSF
09:50:25,034 INFO  [org.wildfly.extension.undertow] (ServerService Thread Pool -- 65) WFLYUT0021: Registered web context: /HelloWorld
09:50:25,060 INFO  [org.jboss.as.server] (ServerService Thread Pool -- 34) WFLYSRV0010: Deployed "mysql-connector-java-5.1.40-bin.jar" (runtime-name : "mysql-connector-java-5.1.40-bin.jar")
09:50:25,061 INFO  [org.jboss.as.server] (ServerService Thread Pool -- 34) WFLYSRV0010: Deployed "HelloWorldJSF.war" (runtime-name : "HelloWorldJSF.war")
09:50:25,061 INFO  [org.jboss.as.server] (ServerService Thread Pool -- 34) WFLYSRV0010: Deployed "HelloWorld.war" (runtime-name : "HelloWorld.war")
09:50:25,159 INFO  [org.jboss.as] (Controller Boot Thread) WFLYSRV0060: Http management interface listening on http://127.0.0.1:9990/management
09:50:25,160 INFO  [org.jboss.as] (Controller Boot Thread) WFLYSRV0051: Admin console listening on http://127.0.0.1:9990
09:50:25,160 INFO  [org.jboss.as] (Controller Boot Thread) WFLYSRV0025: WildFly Full 10.1.0.Final (WildFly Core 2.2.0.Final) started in 3828ms - Started 521 of 783 services (424 services are lazy, passive or on-demand)

网站部署到:

  

C:\ wildfly-10.1.0.Final \独立\部署

我实际上使用了两个网络项目。我自己创建了一个,我直接从教程中获取了另一个。该教程没有说明其他配置。我错过了什么?

1 个答案:

答案 0 :(得分:0)

确保您尝试的网址是以下网址之一:

ages_of_people_waiting_outside_club = [18,27,16,17]
ages_of_people_waiting_outside_club = range(0,100)
for ids in range(0,100):
    if ids >= 18:
        print("you may enter")
    else:
        print("sorry, you can not come in")