Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Castor XML 1.4.1 cannot handle attribute "location" #92

Open
SeabiscuitCZX opened this issue Sep 26, 2022 · 0 comments
Open

Castor XML 1.4.1 cannot handle attribute "location" #92

SeabiscuitCZX opened this issue Sep 26, 2022 · 0 comments

Comments

@SeabiscuitCZX
Copy link

SeabiscuitCZX commented Sep 26, 2022

Recently we would like to upgrade castor xml and castor core from version 1.1.2.1 to 1.4.1 for fixing CVE issue. but we get below exception. as per debug i found laster castor xml cannot handle location attribute. please help to check if it's issue. if not kindly give suggetion how to fix. you can find details in below.

java.lang.IllegalStateException: No Introspector defined in properties!
at org.exolab.castor.xml.util.resolvers.ByIntrospection.internalResolve(ByIntrospection.java:80)
at org.exolab.castor.xml.util.resolvers.AbstractResolverClassCommand.resolve(AbstractResolverClassCommand.java:50)
at org.exolab.castor.xml.util.resolvers.CastorXMLStrategy.getDescriptor(CastorXMLStrategy.java:134)
at org.exolab.castor.xml.util.resolvers.CastorXMLStrategy.resolveClass(CastorXMLStrategy.java:81)
at org.exolab.castor.xml.util.XMLClassDescriptorResolverImpl.resolve(XMLClassDescriptorResolverImpl.java:284)
at org.exolab.castor.xml.MarshalFramework.searchInheritance(MarshalFramework.java:499)
at org.exolab.castor.xml.StartElementProcessor.compute(StartElementProcessor.java:233)
at org.exolab.castor.xml.UnmarshalHandler.startElementProcessing(UnmarshalHandler.java:796)
at org.exolab.castor.xml.UnmarshalHandler.startElement(UnmarshalHandler.java:723)
at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:694)
at org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:589)

Data mapping file
`

<include href="com/test/BaseResponseVO-mapping.xml"/>

<class name="com.test.DetailsResponseVO"
		extends="com.test.BaseResponseVO"
		auto-complete="true">

	<map-to xml="response" />
	
	<field name="userId" type="java.lang.String">
		<bind-xml name="userId" node="element" location="data"/>
	</field>
    		
</class>

`

sample xml response:
<response> <data> <userId></userId> </data> </response>

@SeabiscuitCZX SeabiscuitCZX changed the title Castor XML attribute "location" Castor XML 1.4.1 cannot handle attribute "location" Sep 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant