Description
In the JAX-WS layer currently, instances of the UnmarshalInfo object are stored on AxisService objects the first time that a doc/lit/wrapped request is sent. The next time a request is sent to the same service, the UnmarshalInfo object is retrieved from the AxisService and a JAXBDSContext instance is created from the information in this object. I believe the storage of the UnmarshalInfo needs to be moved to the AxisOperation. Consider the scenario where an AxisService represents a web service with two methods. One of these methods uses doc/lit/wrapped style, but the other uses doc/lit/bare. Once a request is sent to the doc/lit/wrapped method, the UnmarshalInfo is stored on the AxisService. Subsequent calls to the doc/lit/bare method will fail because a JAXBDSContext will be created using the UnmarshalInfo for the doc/lit/wrapped method. Even though this only includes information about the packages, the constructed JAXBDSContext will not know what Java type the bare request parameters should be unmarshalled into, thus causing a JAXB UnmarshallException.