You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by Mark Webb <el...@gmail.com> on 2006/11/27 15:44:39 UTC

IoService question

I was looking at the IoService class and noticed that there are some fields
that would be nice to have:

    long getCreationTime();
    long getReadBytes();
    long getWrittenBytes();
    long getReadMessages();
    long getWrittenMessages();

These methods are in the IoSession interface, and thought it would make
sense to also have them in the IoService interface.  The last 4 might be a
little tougher to implement, but it would be nice for times in which we need
some performance numbers.

comments/questions?
Thank you.

Re: IoService question

Posted by Trustin Lee <tr...@gmail.com>.
On 11/27/06, Mark Webb <el...@gmail.com> wrote:
>
> I was looking at the IoService class and noticed that there are some
> fields
> that would be nice to have:
>
>     long getCreationTime();
>     long getReadBytes();
>     long getWrittenBytes();
>     long getReadMessages();
>     long getWrittenMessages();
>
> These methods are in the IoSession interface, and thought it would make
> sense to also have them in the IoService interface.  The last 4 might be a
> little tougher to implement, but it would be nice for times in which we
> need
> some performance numbers.
>
> comments/questions?


Sounds like a good idea.  But wouldn't we need any synchronization which
might degrade performance?  We could just skip synchronization if we just
want approximate numbers.

Trustin
-- 
what we call human nature is actually human habit
--
http://gleamynode.net/
--
PGP key fingerprints:
* E167 E6AF E73A CBCE EE41  4A29 544D DE48 FE95 4E7E
* B693 628E 6047 4F8F CFA4  455E 1C62 A7DC 0255 ECA6