Hi Brett,

Dims is right, this is a bug and is partially resolved (thanks to Brian Husted) in the current CVS version.

http://issues.apache.org/jira/browse/AXIS-2084
http://issues.apache.org/jira/browse/AXIS-2158

Hope this helps,
Tom

Brett wrote:
Folks,

I am using Axis 1.2.1 to upload DIME attachments (PDF docs) to an Asp.Net Web Service with WSE2. For small attachments (less than 1 MB) the file upload works fine. When the size increases to over 1 MB the Microsoft Web Services Extension throws an error. I am aware that maxRequestLength for httpRuntime and messaging in the web.config file need to be properly set for large attachments. However the error I get indicates that DIME records are out of sequence. The error message is as follows:

HTTP/ASMX Message Receive Failure: Microsoft.Web.Services2.Dime.DimeFormatException: WSE309: The Type_T of the middle record chunk must not be 0 (Type_T=Unchanged).

at Microsoft.Web.Services2.Dime.DimeRecord.CheckValid(String type, String id, TypeFormat typeFormat)

   at Microsoft.Web.Services2.Dime.DimeRecord.ReadHeader()

at Microsoft.Web.Services2.Dime.DimeRecord.ReadBody(Byte[] buffer, Int32 offset, Int32 count)

at Microsoft.Web.Services2.Dime.DimeStream.Read(Byte[] buffer, Int32 offset, Int32 count)

at Microsoft.Web.Services2.StreamHelper.BinaryCopy(Stream from, Stream to, Int32 bufferSize)

at Microsoft.Web.Services2.StreamHelper.BinaryCopy(Stream from, Stream to)

at Microsoft.Web.Services2.Dime.DimeAttachmentCollection..ctor(DimeReader reader)

at Microsoft.Web.Services2.Messaging.SoapDimeFormatter.Microsoft.Web.Services2.Messaging.ISoapFormatter.Deserialize(Stream stream)

at Microsoft.Web.Services2.WebServicesExtension.BeforeDeserializeServer(SoapServerMessage message)

The Web Service is clearly not expecting a 0 length record.

When I look at the packets that come into the server from the uploading client during the failing sequence I see the following:

- HTTP Request with the last chunk of the PDF file

- HTTP Request with six bytes of zero from the client

- TCP acknowledgement from the server

- HTTP Reply from server 400 Bad Request

A successful DIME upload has this sequence:

- HTTP Request with the last chunk of the PDF file

- TCP acknowledgement from the server

- HTTP Request with six bytes of zero from the client

- HTTP Reply from server 200 OK

It seems as though Axis is sending an out of sequence request when the DIME attachment fails. It is worthwhile noting that all the data uploads to the server (even for files as large as 11 MB) it is the termination sequence that is problematic.

Thanks for any help,

Brett

Reply via email to