Giambattista, Can you open a JIRA issue [1] and attach the AAR file to the issue?
Andreas [1] https://issues.apache.org/jira/ On Sat, Jul 10, 2010 at 14:33, Giambattista - WS <[email protected]> wrote: > Hello, > > thanks for your reply. > I tested a simple service with a method that return an object with a > DataHandler field with axis2 1.5.1 downloaded war version from here: > http://ws.apache.org/axis2/download.cgi > > I found the axiom libraries 1.2.8 inside, everything works fine. > > I downloaded the axiom 1.2.9 snapshots from > http://repository.apache.org/snapshots/org/apache/ws/commons/axiom/ > and I substituted the library into webapps/axis2/WEB-INF/lib > > Tested again the same service and the MTOM optimization doesn't work. > > Can you help me? > I can send the code if you think it can be useful. > > thanks > regards > > > > Il giorno mer, 07/07/2010 alle 21.20 +0200, Andreas Veithen ha scritto: >> Giambattista, >> >> This is not the support forum of WSO2. You will have to test this >> first with an Axis2 version produced by the Axis2 project. >> >> Andreas >> >> On Sun, Jul 4, 2010 at 19:46, Giambattista - WS <[email protected]> >> wrote: >> > Hello, >> > >> > My name is Giambattista Pisasale, from WebScience, Milan, Italy. >> > >> > I'm working with WSAS 3.2.0 /Axis2 1.6.0 / axiom 1.2.9 >> > I've an issue, I think that is a regression because everything works >> > fine with WSAS 3.1.3 / axis2 1.5.0 / axiom 1.2.7. >> > >> > I've a simple AAR service with the method >> > Document getDocument(String uuid); >> > >> > that returns a (simple) object like this: >> > >> > public class Document { >> > private String UUID; >> > private DataHandler fileContent; >> > ...(getters / setters ) >> > } >> > >> > The problem is that the service doesn't optimize the attachment and the >> > file content is printed inline: >> > this is what I expected and what the service return with wsas 3.1.3: >> > <return xsi:type="ax21:Document" >> > xmlns:ax21="http://dao.dlsvc.ds.sisal.webscience.it/xsd" >> > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> >> > <UUID>uuidprova</UUID> >> > <fileContent> >> > <xop:Include >> > href="cid:1.urn:uuid:[email protected]" >> > xmlns:xop="http://www.w3.org/2004/08/xop/include"/> >> > </fileContent> >> > ...... >> > >> > while this is what the service returns with wsas 3.2.0: >> > <return xsi:type="ax21:Document" >> > xmlns:ax21="http://dao.dlsvc.ds.sisal.webscience.it/xsd" >> > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> >> > <UUID>uuidprova</UUID> >> > <companyId>0</companyId> >> > <fileContent> >> > asdfasdfasdfasdfasdfasdfasdfsadfasdfasdfasdfasdfads >> > </fileContent> >> > .......... >> > >> > The only workaround I found is to use the bean generated by wsdl2java >> > utility, overwriting the original one. >> > >> > follow the log with trace level for org.apache.axiom.* : >> > >> > [2010-07-04 19:22:03,954] (org.apache.axiom.om.OMOutputFormat - 140) >> > DEBUG - Start getContentType: OMOutputFormat [ mimeBoundary =null >> > rootContentId=null doOptimize=true doingSWA=false isSOAP11=false >> > charSetEncoding=UTF-8 xmlVersion=null contentType=null >> > ignoreXmlDeclaration=false autoCloseWriter=true actionProperty=null >> > optimizedThreshold=0] >> > [2010-07-04 19:22:03,958] (org.apache.axiom.om.OMOutputFormat - 166) >> > DEBUG - getContentType= {multipart/related; >> > boundary="MIMEBoundaryurn_uuid_DA769DE35388AA2ED61278264125205"; >> > type="application/xop+xml"; >> > start="<0.urn:uuid:[email protected]>"; >> > start-info="application/soap+xml"} OMOutputFormat [ mimeBoundary >> > =MIMEBoundaryurn_uuid_DA769DE35388AA2ED61278264125205 >> > rootContentId=0.urn:uuid:[email protected] >> > doOptimize=true doingSWA=false isSOAP11=false charSetEncoding=UTF-8 >> > xmlVersion=null contentType=application/soap+xml >> > ignoreXmlDeclaration=false autoCloseWriter=true actionProperty=null >> > optimizedThreshold=0] >> > [2010-07-04 19:22:03,962] (org.apache.axiom.om.impl.MTOMXMLStreamWriter >> > - 91) DEBUG - OutputStream =class java.io.BufferedOutputStream >> > [2010-07-04 19:22:03,963] (org.apache.axiom.om.impl.MTOMXMLStreamWriter >> > - 92) DEBUG - OMFormat = OMOutputFormat [ mimeBoundary >> > =MIMEBoundaryurn_uuid_DA769DE35388AA2ED61278264125205 >> > rootContentId=0.urn:uuid:[email protected] >> > doOptimize=true doingSWA=false isSOAP11=false charSetEncoding=UTF-8 >> > xmlVersion=null contentType=application/soap+xml >> > ignoreXmlDeclaration=false autoCloseWriter=true actionProperty=null >> > optimizedThreshold=0] >> > [2010-07-04 19:22:03,965] (org.apache.axiom.om.impl.MTOMXMLStreamWriter >> > - 95) TRACE - Call Stack =DEBUG_FRAME = >> > org.apache.axiom.om.util.CommonUtils.callStackToString(CommonUtils.java:80) >> > DEBUG_FRAME = >> > org.apache.axiom.om.impl.MTOMXMLStreamWriter.<init>(MTOMXMLStreamWriter.java:95) >> > DEBUG_FRAME = >> > org.apache.axiom.om.impl.llom.OMSerializableImpl.serializeAndConsume(OMSerializableImpl.java:191) >> > DEBUG_FRAME = >> > org.apache.axis2.transport.http.SOAPMessageFormatter.writeTo(SOAPMessageFormatter.java:79) >> > DEBUG_FRAME = >> > org.apache.axis2.transport.http.CommonsHTTPTransportSender.sendUsingOutputStream(CommonsHTTPTransportSender.java:361) >> > DEBUG_FRAME = >> > org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:238) >> > DEBUG_FRAME = >> > org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:443) >> > DEBUG_FRAME = >> > org.apache.axis2.receivers.AbstractInOutMessageReceiver.invokeBusinessLogic(AbstractInOutMessageReceiver.java:43) >> > DEBUG_FRAME = >> > org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:114) >> > DEBUG_FRAME = >> > org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:178) >> > DEBUG_FRAME = >> > org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:173) >> > DEBUG_FRAME = >> > org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:144) >> > DEBUG_FRAME = >> > javax.servlet.http.HttpServlet.service(HttpServlet.java:709) >> > DEBUG_FRAME = >> > javax.servlet.http.HttpServlet.service(HttpServlet.java:802) >> > DEBUG_FRAME = >> > org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleRequest(ServletRegistration.java:90) >> > DEBUG_FRAME = >> > org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:111) >> > DEBUG_FRAME = >> > org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:67) >> > DEBUG_FRAME = >> > javax.servlet.http.HttpServlet.service(HttpServlet.java:802) >> > DEBUG_FRAME = >> > org.wso2.carbon.bridge.BridgeServlet.service(BridgeServlet.java:154) >> > DEBUG_FRAME = >> > javax.servlet.http.HttpServlet.service(HttpServlet.java:802) >> > DEBUG_FRAME = >> > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269) >> > DEBUG_FRAME = >> > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188) >> > DEBUG_FRAME = >> > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210) >> > DEBUG_FRAME = >> > org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174) >> > DEBUG_FRAME = >> > org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) >> > DEBUG_FRAME = >> > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) >> > DEBUG_FRAME = >> > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108) >> > DEBUG_FRAME = >> > org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151) >> > DEBUG_FRAME = >> > org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870) >> > DEBUG_FRAME = org.apache.coyote.http11.Http11BaseProtocol >> > $Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665) >> > DEBUG_FRAME = >> > org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528) >> > DEBUG_FRAME = >> > org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81) >> > DEBUG_FRAME = org.apache.tomcat.util.threads.ThreadPool >> > $ControlRunnable.run(ThreadPool.java:685) >> > DEBUG_FRAME = java.lang.Thread.run(Thread.java:619) >> > >> > [2010-07-04 19:22:03,972] (org.apache.axiom.om.util.StAXUtils - 582) >> > DEBUG - About to create XMLOutputFactory implementation with >> > classloader=org.eclipse.core.runtime.internal.adaptor.contextfin...@13515e >> > [2010-07-04 19:22:03,972] (org.apache.axiom.om.util.StAXUtils - 584) >> > DEBUG - The classloader for javax.xml.stream.XMLOutputFactory is: >> > org.eclipse.osgi.internal.baseadaptor.defaultclassloa...@1bd9d76 >> > [2010-07-04 19:22:03,990] (org.apache.axiom.om.util.StAXUtils - 602) >> > DEBUG - Created XMLOutputFactory = class >> > org.apache.axiom.util.stax.wrapper.ImmutableXMLOutputFactory for >> > classloader=org.eclipse.core.runtime.internal.adaptor.contextfin...@13515e >> > [2010-07-04 19:22:03,991] (org.apache.axiom.om.util.StAXUtils - 604) >> > DEBUG - Size of XMLOutputFactory map =1 >> > [2010-07-04 19:22:04,002] >> > (org.apache.axiom.om.impl.util.OMSerializerUtil - 346) DEBUG - The >> > value of xsi:type is ax21:Document >> > [2010-07-04 19:22:04,025] (org.apache.axiom.om.impl.MTOMXMLStreamWriter >> > - 182) DEBUG - Calling MTOMXMLStreamWriter.flush >> > [2010-07-04 19:22:04,026] (org.apache.axiom.om.impl.MTOMXMLStreamWriter >> > - 190) DEBUG - The XML writing is completed. Now the attachments are >> > written >> > [2010-07-04 19:22:04,077] (org.apache.axiom.om.impl.MTOMXMLStreamWriter >> > - 172) DEBUG - close >> > >> > Can you help me !? >> > >> > thanks a lot. >> > Giambattista Pisasale >> > >> > >> > >> > >> > --------------------------------------------------------------------- >> > To unsubscribe, e-mail: [email protected] >> > For additional commands, e-mail: [email protected] >> > >> > >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
