Caspar,

AFAIK the java implementation of Hessian encodes in a streaming
fashion so you don't know when you start encoding the response how
large the encoded payload will be.

I think this would require you to do a double pass when encoding the
response, e.g. encode the response to a byte array, whose length you
can count, and then re-encode the same data setting a header in the
response to indicate the length. There are obviously various other
hacks you could do to save encoding everything twice (i.e. to add the
length to an encoded piece of data), but that's up to your
imagination.

BTW, what are sending that is so large that it requires the overhead
of a progress status?

HTH,

Ben

On 8/16/07, Casper Bang <[EMAIL PROTECTED]> wrote:
> I only recently learned about Hessian, after developing my own
> HttpServlet <-> UrlConnection binary service framework. I would like to
> use Hessian but I am missing one feature. In my framework, I place the
> size of the serialized data in the Content-Length header of a response,
> such as to allow for progress bar to be updated accordingly on a client.
> Is there a similar approach for monitoring the transfer in Hessian, or
> is it strictly a blocking proxy?
>
> Regards,
> Casper
>
>
> _______________________________________________
> hessian-interest mailing list
> [email protected]
> http://maillist.caucho.com/mailman/listinfo/hessian-interest
>


_______________________________________________
hessian-interest mailing list
[email protected]
http://maillist.caucho.com/mailman/listinfo/hessian-interest

Reply via email to