Avoid using Java package names starting with "com.ibm" in application code
 Technote (troubleshooting)
 
Problem(Abstract)
Java™ package names starting with "com.ibm" should be avoided in application code. The following is seen in the SystemOut.log when invoking a Web Service:

org.xml.sax.SAXException: WSWS3047E: Error: Cannot deserialize element
sample of bean com.ibm.w3.Component.
at
com.ibm.ws.webservices.engine.encoding.ser.BeanDeserializer.onStartChild
(BeanDeserializer.java:297)
at
com.ibm.ws.webservices.engine.events.DEventProcessor.onSimpleChild(DEventProcessor.java:212)
at
com.ibm.ws.webservices.engine.encoding.ser.BeanDeserializer.onSimpleChil
d(BeanDeserializer.java:417)


where "sample" is the name of an element inside a 'Component' complexType.
 
Cause
Consider the following XSD Schema found in a WSDL:

<schema targetNamespace="http://w3.ibm.com/ ... />
...
<complexType name="Component">
<sequence>
<element name="sample" nillable="true" type="xsd:string"/>
</sequence>
</complexType>
...


This will cause the above SAXException to be written to the SystemOut.log.

This is a limitation with all releases of IBM® WebSphere® Application Server V5.0 and V5.1.0 ONLY.

Java Reflection is used to find the property descriptors for the "Component" class belonging in the com.ibm.* package. It finds the wrong property descriptors.

The correct property descriptors are found in all releases of Application Server V5.1.1 and V6.0, so the problem does not occur in these versions.

 
Resolving the problem
There are two options to resolve the problem:
1) Rename the package so that it does not start with com.ibm.*
2) Rename the "Component" class.
 
 
Cross Reference information
Segment Product Component Platform Version Edition
Application Servers Runtimes for Java Technology Java SDK
 
 


Document Information


Product categories: Software > Application Servers > Distributed Application & Web Servers > WebSphere Application Server > Web Services (for example: SOAP or UDDI or WSGW or WSIF)
Operating system(s): Windows
Software version: 5.1.0.6
Software edition:
Reference #: 1213291
IBM Group: Software Group
Modified date: Jul 31, 2005