[jboss-jira] [JBoss JIRA] (WFLY-3189) Error validating jboss-ejb3.xml.
Wolfgang Knauf (JIRA)
issues at jboss.org
Fri Aug 15 15:56:30 EDT 2014
[ https://issues.jboss.org/browse/WFLY-3189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12993307#comment-12993307 ]
Wolfgang Knauf commented on WFLY-3189:
--------------------------------------
One additional validation problem:
I pulled "jboss-ejb3-2_0.xsd" and "jboss-ejb3-spec-2_0.xsd" in an Eclipse project. Here, there was only one validation error:
cos-nonambig: "http://java.sun.com/xml/ns/javaee":assembly-descriptor and "http://java.sun.com/xml/ns/javaee":assembly-descriptor (or elements from their substitution group) violate "Unique Particle Attribution". During validation against this schema, ambiguity would be created for those two particles.
In file "jboss-ejb3-spec-2_0.xsd", line 126
This is this line:
<xs:complexType name="jboss-ejb-jarType">
<xs:complexContent>
<xs:extension base="javaee:ejb-jarType">
<xs:sequence>
<xs:element ref="jboss:enterprise-beans" minOccurs="0"/>
<xs:element name="assembly-descriptor" type="javaee:assembly-descriptorType" minOccurs="0"/>
</xs:sequence>
<xs:attribute name="impl-version" type="javaee:dewey-versionType" fixed="2.0" use="required"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
I think the problem is the "assembly-descriptor" definition: this one is already defined in the base type "javaee:ejb-jarType", and thus it results in an error. If I remove this line, at least those two files validate.
But after creating "jboss-ejb3.xml" file, I observe the same "Cannot resolve the name..." errors.
> Error validating jboss-ejb3.xml.
> --------------------------------
>
> Key: WFLY-3189
> URL: https://issues.jboss.org/browse/WFLY-3189
> Project: WildFly
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: EJB
> Affects Versions: 8.0.0.Final
> Environment: WildFly 8.0.0.Final
> Reporter: shinzey shinzey
> Assignee: David Lloyd
>
> I'm trying to configure code completion for jboss-ejb3.xml with schema, but fail to do that due to the following validation error:
> {noformat}
> src-resolve: Cannot resolve the name 'javaee:jboss-ejb-beanType' to a(n) 'type definition' component. [33]
> src-resolve: Cannot resolve the name 'javaee:jboss-ejb-jarType' to a(n) 'type definition' component. [35]
> src-resolve: Cannot resolve the name 'javaee:jboss-enterprise-beansType' to a(n) 'type definition' component. [37]
> src-resolve: Cannot resolve the name 'javaee:assembly-descriptor-entry' to a(n) 'element declaration' component. [35]
> src-resolve: Cannot resolve the name 'javaee:jboss-assembly-descriptor-bean-entryType' to a(n) 'type definition' component. [39]
> {noformat}
> The jboss-ejb3.xml is quite simple:
> {code:xml}
> <?xml version="1.0" encoding="UTF-8"?>
> <jboss:ejb-jar version="3.1" impl-version="2.0"
> xmlns="http://java.sun.com/xml/ns/javaee"
> xmlns:jboss="http://www.jboss.com/xml/ns/javaee"
> xmlns:s="urn:security:1.1"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_1.xsd
> http://www.jboss.com/xml/ns/javaee http://www.jboss.org/j2ee/schema/jboss-ejb3-2_0.xsd">
> <assembly-descriptor>
> <s:security>
> <ejb-name>*</ejb-name>
> <s:security-domain>testsd</s:security-domain>
> </s:security>
> </assembly-descriptor>
> </jboss:ejb-jar>
> {code}
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
More information about the jboss-jira
mailing list