You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by Do...@softechnics.com on 2008/02/15 15:42:20 UTC

NormalizedMessage reports wrong length

I've built and deployed a SE (using the ServiceMix tutorial as a
baseline) that receives a NormalizedMessage via processInOut(), parses
it, acts on it and sends it back to the client.

When I build the SE (mvn clean install), the Unit test that runs as part
of the build process works OK and returns a ByteStream length of 308.
When I deploy the SE to ServiceMix and run the client, it returns a
length of 317. Both instances are delivering the exact same data.

As a result (I believe) of the wrong data length being returned, I get a
XMLReader.parser() error: "[Fata Error] :-1:-1: Premature end of file"

The only explanation I can come up with is the ServiceMix XML packet has
trailing null characters that are being included. I've done a
byte-by-byte comparison of the two packets using MS Debug, so nulls at
the end of the ByteStream would be indistinguishable from the NULLS that
Debug uses to fill a sector during display.

If this is the case, then I guess there's a bug in Servicemix.

Any thoughts?

Doug