Capedwarf:javax.xml.stream.XMLStreamException:[row,col]处的ParseError:[3,1]

时间:2016-11-08 11:14:19

标签: java eclipse jboss wildfly capedwarf

我尝试按照Debuggin an application in Wildfly with EclipseJBoss Tools - Debugging an Externally launched WildFly中的说明在调试模式下运行我的应用程序但是,当我执行 ./ standalone.sh --debug --server-时config = standalone.xml 命令,我收到此错误:

  

user @ user:〜/ wildfly-8.1.0.CR1 / bin $ ./standalone.sh --debug --server-config = standalone-capedwaf-modules.xml

     
    

=============================================== ==========================

  
JBoss Bootstrap Environment

JBOSS_HOME: /home/giacomo/wildfly-8.1.0.CR1

JAVA: java

JAVA_OPTS:  -server -Xms64m -Xmx512m -XX:MaxPermSize=256m -Djava.net.preferIPv4Stack=true -Djboss.modules.system.pkgs=org.jboss.byteman -Djava.awt.headless=true -agentlib:jdwp=transport=dt_socket,address=8787,server=y,suspend=n
     

=============================================== ==========================       在地址收听传输dt_socket:8787 11:11:47,210 INFO [org.jboss.modules](主要)JBoss Modules版本1.3.3.Final   11:11:47,415 INFO [org.jboss.msc](主要)JBoss MSC版本   1.2.2.Final 11:11:47,490 INFO [org.jboss.as](MSC服务主题1-8)JBAS015899:JBoss Capedwarf 2.0.1.Final(WildFly 8.1.0.CR1)开始   11:11:47,812 ERROR [org.jboss.as.server](控制器启动线程)   JBAS015956:引导期间捕获异常:   org.jboss.as.controller.persistence.ConfigurationPersistenceException:   JBAS014676:无法解析配置   org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:112)   [wildfly-controller-8.1.0.CR1.jar:8.1.0.CR1] at   org.jboss.as.server.ServerService.boot(ServerService.java:331)   [wildfly-server-8.1.0.CR1.jar:8.1.0.CR1] at   org.jboss.as.controller.AbstractControllerService $ 1.run(AbstractControllerService.java:256)   [wildfly-controller-8.1.0.CR1.jar:8.1.0.CR1] at   java.lang.Thread.run(Thread.java:745)[rt.jar:1.7.0_80]引起:   javax.xml.stream.XMLStreamException:[row,col]处的ParseError:[3,1]   消息:意外的元素' {urn:jboss:domain:2.2}服务器'在   org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:108)   [staxmapper-1.1.0.Final.jar:1.1.0.Final] at   org.jboss.staxmapper.XMLMapperImpl.parseDocument(XMLMapperImpl.java:69)   [staxmapper-1.1.0.Final.jar:1.1.0.Final] at   org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:104)   [wildfly-controller-8.1.0.CR1.jar:8.1.0.CR1] ......还有3个       11:11:47,814 FATAL [org.jboss.as.server](控制器启动线程)JBAS015957:服务器启动以不可恢复的方式失败;   退出。有关详细信息,请参阅先前的消息。

我认为错误发生在[row,col]的standalone.xml中:[3,1]但我不知道出了什么问题。 在我的.xml下面:

<?xml version='1.0' encoding='UTF-8'?>

<server xmlns="urn:jboss:domain:2.1">

<extensions>
    <extension module="org.jboss.as.capedwarf"/>
    <extension module="org.jboss.as.clustering.infinispan"/>
    <extension module="org.jboss.as.clustering.jgroups"/>
    <extension module="org.jboss.as.connector"/>
    <extension module="org.jboss.as.deployment-scanner"/>
    <extension module="org.jboss.as.ee"/>
    <extension module="org.jboss.as.ejb3"/>
    <extension module="org.jboss.as.jaxrs"/>
    <extension module="org.jboss.as.jmx"/>
    <extension module="org.jboss.as.jpa"/>
    <extension module="org.jboss.as.jsf"/>
    <extension module="org.jboss.as.logging"/>
    <extension module="org.jboss.as.mail"/>
    <extension module="org.jboss.as.messaging"/>
    <extension module="org.jboss.as.naming"/>
    <extension module="org.jboss.as.remoting"/>
    <extension module="org.jboss.as.security"/>
    <extension module="org.jboss.as.transactions"/>
    <extension module="org.jboss.as.weld"/>
    <extension module="org.wildfly.extension.io"/>
    <extension module="org.wildfly.extension.undertow"/>
</extensions>





<management>
    <security-realms>
        <security-realm name="ManagementRealm">
            <authentication>
                <local default-user="$local"/>
                <properties path="mgmt-users.properties" relative-to="jboss.server.config.dir"/>
            </authentication>
            <authorization map-groups-to-roles="false">
                <properties path="mgmt-groups.properties" relative-to="jboss.server.config.dir"/>
            </authorization>
        </security-realm>
        <security-realm name="ApplicationRealm">
            <authentication>
                <local default-user="$local" allowed-users="*"/>
                <properties path="application-users.properties" relative-to="jboss.server.config.dir"/>
            </authentication>
            <authorization>
                <properties path="application-roles.properties" relative-to="jboss.server.config.dir"/>
            </authorization>
        </security-realm>
    </security-realms>
    <management-interfaces>
        <native-interface security-realm="ManagementRealm">
            <socket-binding native="management-native"/>
        </native-interface>
        <http-interface security-realm="ManagementRealm" http-upgrade-enabled="true">
            <socket-binding http="management-http"/>
        </http-interface>
    </management-interfaces>
</management>



<profile>
    <subsystem xmlns="urn:jboss:domain:capedwarf:1.0"/>
    <subsystem xmlns="urn:jboss:domain:logging:2.0">
        <console-handler name="CONSOLE">
            <level name="INFO"/>
            <formatter>
                <pattern-formatter pattern="%K{level}%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
            </formatter>
        </console-handler>
        <periodic-rotating-file-handler name="FILE" autoflush="true">
            <formatter>
                <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
            </formatter>
            <file relative-to="jboss.server.log.dir" path="server.log"/>
            <suffix value=".yyyy-MM-dd"/>
            <append value="true"/>
        </periodic-rotating-file-handler>
        <logger category="com.arjuna">
            <level name="WARN"/>
        </logger>
        <logger category="org.apache.tomcat.util.modeler">
            <level name="WARN"/>
        </logger>
        <logger category="org.jboss.as.config">
            <level name="DEBUG"/>
        </logger>
        <logger category="sun.rmi">
            <level name="WARN"/>
        </logger>
        <logger category="jacorb">
            <level name="WARN"/>
        </logger>
        <logger category="jacorb.config">
            <level name="ERROR"/>
        </logger>
        <root-logger>
            <level name="INFO"/>
            <handlers>
                <handler name="CONSOLE"/>
                <handler name="FILE"/>
            </handlers>
        </root-logger>
    </subsystem>
    <subsystem xmlns="urn:jboss:domain:datasources:2.0">
        <datasources>
            <datasource jndi-name="java:jboss/datasources/ExampleDS" pool-name="ExampleDS"
     

启用=&#34;真&#34;使用Java的上下文=&#34;真&#34;&GT;                       JDBC:H2:MEM:测试; DB_CLOSE_DELAY = -1                       H2                                                  SA                           SA                                                                                                               org.h2.jdbcx.JdbcDataSource                                                                                                                                   假               真正                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

你可以帮帮我吗? 感谢。

2 个答案:

答案 0 :(得分:1)

命令行中有拼写错误:

./standalone.sh --debug --server-config=standalone-capedwaf-modules.xml

capedwaf应为capedwarf

答案 1 :(得分:0)

你是如何使用/建立CapeDwarf扩展的?

我看到你正在使用上游大师 - 因为(不幸的是)我们从未发布2.0.1.Final ......: - (

因为capedwarf-jboss-as使用WF 8.2.1.Final:https://github.com/capedwarf/capedwarf-jboss-as/blob/master/pom.xml#L57

我建议你从官方下载中使用CapeDwarf 2.0.0.Final。

如果你还有一些问题,请告诉我,我会尝试使用修复程序进行新版本。 ; - )