On Fri, 22 Feb 2008 02:20:12 +0900, Geoff Cadien <[EMAIL PROTECTED]> wrote:

On Tue, Feb 19, 2008 at 7:53 PM, ÀÌÈñ½Â (Trustin Lee) <[EMAIL PROTECTED]>
wrote:

2008-02-14 (¸ñ), 12:02 -0700, Mike Heath ¾²½Ã±æ:
> Geoff Cadien wrote:
> > On Thu, Feb 14, 2008 at 10:30 AM, Mike Heath <[EMAIL PROTECTED]>
wrote:
> >
> >> DIRMINA-524 is fixed
> >> DIRMINA-525 is also fixed and I wrote a test for the fix
> >>
> >> Thanks for the patches and thanks for following up on these issues.
> >
> >
> > Mike,
> >
> > Thanks for getting to those so quickly.  Regarding
> > https://issues.apache.org/jira/browse/DIRMINA-526 Do you know of
another way
> > to get the number of bytes sent to the client when the entire message
isn't
> > sent?
> >
> > Thanks,
> >
> > -geoff
> >
>
> I can't think of any way to do this off the top of my head. Perhaps we > should consider updating the written byte count as data is sent and not
> just when a message completes.  I'm not sure what the performance
> implications of this would be.
>
> I'll play around with it and see what I can determine.

I'd prefer to update the counter as soon as a single write operation
completes.  Exposing getCurrentWriteRequest() is another matter though.


Another thing having access to getCurrentWriteRequest() makes easier is
being able to easily determine in sessionClosed whether or not the entire
message was sent.  Currently it's *possible* for me to determine if the
message was completely sent but requires a lot of juggling of things in the
session.

All done. Counters are updated as soon as possible, and you know what message is being written right now via IoSession.getCurrentWriteMessage() and getCurrentWriteRequest().

HTH,

--
Trustin Lee - Principal Software Engineer, JBoss, Red Hat
--
what we call human nature is actually human habit
--
http://gleamynode.net/

Reply via email to