i tried with smaller chunks too (1024b), but this didn't help.
meanwhile i wrote some work-around that seems to work, but still, i
don't understand why the solution above does not.

            int read;
            ByteArrayOutputStream baos = new ByteArrayOutputStream();

            while((read = zis.read()) >= 0)
            {
                baos.write(read);
                if(baos.size() ==
BlobstoreService.MAX_BLOB_FETCH_SIZE)
                {
                    ByteBuffer bb =
ByteBuffer.wrap(baos.toByteArray());
                    writeChannel.write(bb);
                    baos = new ByteArrayOutputStream();
                }
            }
            if(baos.size() > 0)
            {
                ByteBuffer bb = ByteBuffer.wrap(baos.toByteArray());
                writeChannel.write(bb);
            }

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en.

Reply via email to