Hi Raghu, I have used JPEG files with Axis2 MTOM earlier, but never came across this issue.. Even the MTOM test cases in Axis2 uses a JPEG file.. What is the size of the file.. If it's small, try to have a look at the message using tcpmon (ws.apache.org/commons/tcpmon).
Did you try with the same JPEG file or did you try testing with different JPEG files.. Anyway it's a gud idea to log a JIRA about this, together with your JPEG file and if possible a test case... thanks, Thilina On Dec 5, 2007 12:58 PM, Raghu Upadhyayula <[EMAIL PROTECTED]> wrote: > > > > > Hi, > > > > I have a webservice which is used to upload images to the server. > > > > I'm getting an exception if I am sending a JPEG file with MTOM enabled. It > works fine if MTOM is not enabled (Base64 encoded). It works fine if I send > a GIF file with or without MTOM enabled. > > > > Here is the exception I'm getting. Is this a bug? (I'm using Axis2 1.3 > Version). > > > > 17:30:43,469 ERROR [[AxisServlet]] Servlet.service() for servlet AxisServlet > threw exception > > java.lang.ArrayIndexOutOfBoundsException > > at java.lang.System.arraycopy(Native Method) > > at org.apache.tomcat.util.buf.ByteChunk.substract(ByteChunk.java:414) > > at org.apache.catalina.connector.InputBuffer.read(InputBuffer.java:312) > > at > org.apache.catalina.connector.CoyoteInputStream.read(CoyoteInputStream.java:193) > > at java.io.BufferedInputStream.fill(Unknown Source) > > at java.io.BufferedInputStream.read1(Unknown Source) > > at java.io.BufferedInputStream.read(Unknown Source) > > at java.io.FilterInputStream.read(Unknown Source) > > at java.io.PushbackInputStream.read(Unknown Source) > > at > org.apache.axiom.attachments.BoundaryPushbackInputStream.readFromStream(BoundaryPushbackInputStream.java:102) > > at > org.apache.axiom.attachments.BoundaryPushbackInputStream.readFromStream(BoundaryPushbackInputStream.java:122) > > at > org.apache.axiom.attachments.BoundaryPushbackInputStream.read(BoundaryPushbackInputStream.java:172) > > at > org.apache.axiom.attachments.MIMEBodyPartInputStream.read(MIMEBodyPartInputStream.java:87) > > at java.io.BufferedInputStream.fill(Unknown Source) > > at java.io.BufferedInputStream.read(Unknown Source) > > at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:75) > > at javax.mail.internet.InternetHeaders.load(InternetHeaders.java:329) > > at javax.mail.internet.InternetHeaders.<init>(InternetHeaders.java:301) > > at javax.mail.internet.MimeBodyPart.<init>(MimeBodyPart.java:168) > > at > org.apache.axiom.attachments.PartOnMemory.<init>(PartOnMemory.java:34) > > at > org.apache.axiom.attachments.Attachments.getPart(Attachments.java:598) > > at > org.apache.axiom.attachments.Attachments.getNextPartDataHandler(Attachments.java:462) > > at > org.apache.axiom.attachments.Attachments.getContentIDSet(Attachments.java:427) > > at > org.apache.axiom.attachments.Attachments.getAllContentIDs(Attachments.java:420) > > at > org.apache.axis2.transport.TransportUtils.deleteAttachments(TransportUtils.java:481) > > at > org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:189) > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:710) > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) > > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) > > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > > at > org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96) > > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > > at > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230) > > at > org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) > > at > org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179) > > at > org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84) > > at > org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) > > at > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) > > at > org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157) > > at > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) > > at > org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262) > > at > org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) > > at > org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) > > at > org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446) > > at java.lang.Thread.run(Unknown Source) > > > > Thanks > > Raghu > > -- Thilina Gunarathne - http://thilinag.blogspot.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
