directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Trustin Lee <trus...@gmail.com>
Subject Re: [MINA] Some Questions
Date Fri, 07 Oct 2005 02:10:51 GMT
Hi Jose,

2005/10/6, Jose Alberto Fernandez <jalberto@cellectivity.com>:
>
> We are evaluating the use of MINA as the server kernel for one of our
> projects.
>
Great. Any questions and requests for support is OK.

> I have been roaming around on the site and the code and have some
> questions.
>
>  1) Are there any stress test numbers or profiling that has been done? I
> have not come across anything yet.
>
Not much yet. Possibly you can provide some benchmark tests for us. It is
known than MINA can handle more than 30k clients at once AFAIK.

> 2) I have been looking at the way things are done in MINA and in
> particular at the ServiceRegistry API and it seem that any filters that one
> sets up apply to all ports and protocols. So I could not have SSL setup on
> one port and no-SSL in another. Is this the case? One would think that one
> should be able to set-up such filtering in a Service by Service basis (i.e.,
> http vs. https).
>
You can add filters to each session. There is a method called
'getFilterChain()' in IoSession and ProtocolSession.

> 3) While trying to understand (2) I noticed the following code in
> SimpleServiceRegistry:
>
> 219 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#219%23219>
    *private* *void* startThreadPools()
>
> 220 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#220%23220>
    {
>
> 221 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#221%23221>
        *if*( !services.isEmpty() )
>
> 222 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#222%23222>
            *return*;
>
> 223 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#223%23223>
>
> 224 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#224%23224>
        ioThreadPoolFilter.start();
>
> 225 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#225%23225>
        protocolThreadPoolFilter.start();
>
> 226 <http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#226%23226>
    }
>
> 227<http://directory.apache.org/subprojects/network/xref/org/apache/mina/registry/SimpleServiceRegistry.html#227%23227>
>
>  Is this correct? You only start the thread pools when there are no
> services? Looks odd.
>

It is correct because startThreadPools() is invoked whenever bind() is
called(). Thread pools should be started only when it is the first bind.

HTH,
Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/

Mime
View raw message