On Monday, December 05, 2011 3:07:42 PM eamiller83 wrote: > I am running CXF 2.4.2 based web services on Tomcat 7. When put under a > moderately heavy load I am occasionally receiving the following error: > > org.apache.cxf.interceptor.Fault: Marshalling Error: cvc-complex-type.2.4.b: > The content of element ... is not complete. One of ... is expected. > > My web services are generated through the CXF Wsdl2Java from my wsdl and xsd > files. The function I am testing uses MTOM to return binary data if that > makes a difference, however the part that fails validation is not the > binary data portion of the response. I have verified through debugging > that the response structure returned by the function in my service > implementation is filled out completely and am pretty confident at this > point that it is not my code that has a concurrency issue. I believe that > the xml marshaller is the problem. > > I am pretty new to CXF and and after hunting around online I have found that > it looks like CXF uses the JAXB marshaller under the hood and that the JAXB > marshaller is not thread safe. However, it also sounds like CXF wraps the > marshaller and makes it thread safe. I was looking for a way to extend the > marshaller class to make the functions synchronized to test the theory but > I have not found a way to specify a marshaller to the CXF context. Does > anyone know what is happening here? Is there some setting that I missed? > Let me know if you need more information. Thanks in advance.
I'm really not sure what would cause this at marshaling time. CXF creates a new Marshaller object every time it needs to marshal something. Thus, that's not the issue. It would only be used for that one invokation and then discarded. Honestly, I have no idea what to suggest for debugging this. :-( -- Daniel Kulp [email protected] - http://dankulp.com/blog Talend Community Coder - http://coders.talend.com
