Uploaded image for project: 'ModeShape'
  1. ModeShape
  2. MODE-2399

ModeShape EAP/WF subsystem incorrectly handles default initial content

    Details

    • Steps to Reproduce:
      Hide

      Start a server (WF/EAP) with the ModeShape subsystem installed and try configuring a default initial content via:
      /subsystem=modeshape/repository=repo:add(cache-container="modeshape",cache-name="repo",security-domain="modeshape-security",use-anonymous-upon-failed-authentication="false",anonymous-roles=["readonly"],default-initial-content="initial-content-default.xml")

      Show
      Start a server (WF/EAP) with the ModeShape subsystem installed and try configuring a default initial content via: /subsystem=modeshape/repository=repo:add(cache-container="modeshape",cache-name="repo",security-domain="modeshape-security",use-anonymous-upon-failed-authentication="false",anonymous-roles=["readonly"],default-initial-content="initial-content-default.xml")

      Description

      When configuring default initial content via CLI for a ModeShape repository the generated configuration XML does not match the schema, resulting in the following error:

      09:03:14,709 ERROR [org.jboss.as.server] (Controller Boot Thread) JBAS015956: Caught exception during boot: org.jboss.as.controller.persistence.ConfigurationPersistenceException: JBAS014676: Failed to parse configuration
              at org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:141) [jboss-as-controller-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at org.jboss.as.server.ServerService.boot(ServerService.java:321) [jboss-as-server-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at org.jboss.as.controller.AbstractControllerService$1.run(AbstractControllerService.java:254) [jboss-as-controller-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at java.lang.Thread.run(Thread.java:724) [rt.jar:1.7.0_40]
      Caused by: javax.xml.stream.XMLStreamException: ParseError at [row,col]:[258,17]
      Message: JBAS014789: Unexpected element '{urn:jboss:domain:modeshape:1.0}initial-content' encountered
              at org.jboss.as.controller.parsing.ParseUtils.unexpectedElement(ParseUtils.java:86) [jboss-as-controller-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at org.modeshape.jboss.subsystem.ModeShapeSubsystemXMLReader_1_0.parseRepository(ModeShapeSubsystemXMLReader_1_0.java:299)
              at org.modeshape.jboss.subsystem.ModeShapeSubsystemXMLReader_1_0.readElement(ModeShapeSubsystemXMLReader_1_0.java:71)
              at org.modeshape.jboss.subsystem.ModeShapeSubsystemXMLReader_1_0.readElement(ModeShapeSubsystemXMLReader_1_0.java:42)
              at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:110) [staxmapper-1.1.0.Final-redhat-2.jar:1.1.0.Final-redhat-2]
              at org.jboss.staxmapper.XMLExtendedStreamReaderImpl.handleAny(XMLExtendedStreamReaderImpl.java:69) [staxmapper-1.1.0.Final-redhat-2.jar:1.1.0.Final-redhat-2]
              at org.jboss.as.server.parsing.StandaloneXml.parseServerProfile(StandaloneXml.java:1035) [jboss-as-server-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at org.jboss.as.server.parsing.StandaloneXml.readServerElement_1_4(StandaloneXml.java:469) [jboss-as-server-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at org.jboss.as.server.parsing.StandaloneXml.readElement(StandaloneXml.java:145) [jboss-as-server-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at org.jboss.as.server.parsing.StandaloneXml.readElement(StandaloneXml.java:107) [jboss-as-server-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
              at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:110) [staxmapper-1.1.0.Final-redhat-2.jar:1.1.0.Final-redhat-2]
              at org.jboss.staxmapper.XMLMapperImpl.parseDocument(XMLMapperImpl.java:69) [staxmapper-1.1.0.Final-redhat-2.jar:1.1.0.Final-redhat-2]
              at org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:133) [jboss-as-controller-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19]
      

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  hchiorean Horia Chiorean
                  Reporter:
                  hchiorean Horia Chiorean
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: