|Re: [eclipselink-users] Stack overflow in generating project.xml|
It's likely that you have hit a bug in the Workbench. Thank you for the detailed info and examples. We will look into this and get back to you.
To ensure that this particular issue is tracked, it would be helpful if you could enter a bug against the EclipseLink Utility component in bugzilla. Just include the information you have provided in your mailing list posts.
https://bugs.eclipse.org/bugs/enter_bug.cgi (you will find EclipseLink under the Technology project (for now))
Hi, I debugged into this issue and found that EclipseLink is getting tangled up in our schemas. What we're doing in the schemas doesn't seem to be that weird, but please tell me if it is. I'm doing an XML-Direct mapping for Address.attentionOfName that has an XPath like "ns1:AttentionOfName/text()". In the top-level schema First.xsd, we have Address defined this way: <xsd:complexType name="AddressBaseType" abstract="true"> <xsd:sequence> <xsd:element ref="AttentionOfName" minOccurs="0" maxOccurs="unbounded"/> ... </xsd:sequence> </xsd:complexType> <xsd:complexType name="AddressType"> <xsd:complexContent> <xsd:extension base="AddressBaseType"> ... </xsd:extension> </xsd:complexContent> </xsd:complexType> The top-level schema includes a second schema: <xsd:include schemaLocation="Second.xsd"/> The second schema includes a third schema: <xsd:include schemaLocation="Third.xsd"/> Third.xsd has: <xsd:element name="AttentionOfName" type="NameType"></xsd:element> and: <xsd:complexType name="NameType"> <xsd:simpleContent> <xsd:extension base="foo:NameType"/> </xsd:simpleContent> </xsd:complexType> Third.xsd references Fourth.xsd this way: xmlns:foo="http://www.foo.org/bar/baz/1.1" <xsd:import namespace="http://www.foo.org/bar/baz/1.1" schemaLocation="../Fourth.xsd"/> Fourth.xsd says: <xsd:complexType name="NameType"> <xsd:simpleContent> <xsd:extension base="xsd:string"> <xsd:attribute name="languageID" type="xsd:language" use="optional"> </xsd:attribute> </xsd:extension> </xsd:simpleContent> </xsd:complexType> By using the debugger, I can see that EclipseLink finds the ComplexType "NameType" declared inside Fourth.xsd (I can tell by the namespace), but then it just keeps going around and around, thinking that foo:NameType extends foo:NameType. It never figures out that foo:NameType extends xsd:string and stops. I looked inside the XML file that the workbench generated for First.xsd, and I can't really make sense of it. I don't see any mention of NameType extending any String type though. Is this kind of configuration supported in EclipseLink? Thanks, Polly amphoras wrote:Just to clarify, I mean that when I right-click the project and select Export -> Project Deployment XML..., I get the stack overflow error. Thanks, Polly
Back to the top