AW: NioSocketConnector/NioSocketAcceptor

2013-08-15 Thread Simo Chiegang, Boris Arthur RD-P8.1
I know. I want to know the meaning of the parameter Processorcount? Und which 
effect has this?


Mit freundlichen Grüßen
Boris Simo RD-P8.1
Steuerung Digitaldruck

Heidelberger Druckmaschinen AG
Kurfürsten-Anlage 52-60
69115 Heidelberg
Phone: +49 6221 92 1234
boris.s...@heidelberg.com
www.heidelberg.com

Heidelberger Druckmaschinen AG • Kurfürsten-Anlage 52–60  • 69115 Heidelberg
Vorsitzender des Aufsichtsrats: Robert J. Koehler
Vorstand: Dr. Gerold Linzbach, Vorsitzender • Dirk Kaliebe • Marcel Kießling • 
Stephan Plenz
Sitz der Gesellschaft: Heidelberg • Amtsgericht Mannheim – Registergericht – 
HRB 330004 • USt.-IdNr. DE 143455661

SAVE PAPER - THINK BEFORE YOU PRINT

-Ursprüngliche Nachricht-
Von: Emmanuel Lécharny [mailto:elecha...@gmail.com]
Gesendet: Donnerstag, 15. August 2013 15:44
An: users@mina.apache.org
Betreff: Re: NioSocketConnector/NioSocketAcceptor

Le 8/15/13 3:21 PM, Simo Chiegang, Boris Arthur RD-P8.1 a écrit :
 Hi guys,

 I want to know, what is he difference between the constructor:


 -  NioSocketConnector() and NioSocketConnector(Processorcount)

 -  NioSocketAcceptor() and NioSocketAcceptor(Processorcount)

 In which case I use which of them?

That's a good question. In fact, those names are so misleading that we renamed 
those classes in MINA 3.

So...

NioSocketConnector is for Client side.
NioSocketAxceptor is fo Server side.


In other words, when you create a client which needs to *connect* to a server, 
you use a NioConnector. And OTOH, when you write a server, whoch will accept 
incoming connections, you use a NioAcceptor.

I hope it's clearer.

--
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com


Confidentiality note:
The information in this email and any attachment may contain confidential and 
proprietary information of Heidelberger Druckmaschinen AG and/or its affiliates 
and may be privileged or otherwise protected from disclosure. If you are not 
the intended recipient, you are hereby notified that any review, reliance or 
distribution by others or forwarding without express permission is strictly 
prohibited and may cause liability. In case you have received this message due 
to an error in transmission, we kindly ask you to notify the sender immediately 
and to delete this email and any attachment from your system.


Re: AW: NioSocketConnector/NioSocketAcceptor

2013-08-15 Thread Emmanuel Lécharny
Le 8/15/13 3:49 PM, Simo Chiegang, Boris Arthur RD-P8.1 a écrit :
 I know. I want to know the meaning of the parameter Processorcount? Und which 
 effect has this?

Ah, that's a different question then.

This parameter tells how many IoProcessor will be spawned to process the
ourgoing and incoming messages.

IoProcessor are selected by the Connector and Acceptor to process the
requests.



-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com 



AW: AW: NioSocketConnector/NioSocketAcceptor

2013-08-15 Thread Simo Chiegang, Boris Arthur RD-P8.1
Ok that  means, when  I write new NioSocketConnector(), the number of threads 
to use isn't no limited. If I give a a processorCount (may be 2 ), I will limit 
the number of threads to 2. I'm wright?


Mit freundlichen Grüßen
Boris Simo RD-P8.1
Steuerung Digitaldruck

Heidelberger Druckmaschinen AG
Kurfürsten-Anlage 52-60
69115 Heidelberg
Phone: +49 6221 92 1234
boris.s...@heidelberg.com
www.heidelberg.com

Heidelberger Druckmaschinen AG • Kurfürsten-Anlage 52–60  • 69115 Heidelberg
Vorsitzender des Aufsichtsrats: Robert J. Koehler
Vorstand: Dr. Gerold Linzbach, Vorsitzender • Dirk Kaliebe • Marcel Kießling • 
Stephan Plenz
Sitz der Gesellschaft: Heidelberg • Amtsgericht Mannheim – Registergericht – 
HRB 330004 • USt.-IdNr. DE 143455661

SAVE PAPER - THINK BEFORE YOU PRINT


-Ursprüngliche Nachricht-
Von: Emmanuel Lécharny [mailto:elecha...@gmail.com]
Gesendet: Donnerstag, 15. August 2013 17:04
An: users@mina.apache.org
Betreff: Re: AW: NioSocketConnector/NioSocketAcceptor

Le 8/15/13 3:49 PM, Simo Chiegang, Boris Arthur RD-P8.1 a écrit :
 I know. I want to know the meaning of the parameter Processorcount? Und which 
 effect has this?

Ah, that's a different question then.

This parameter tells how many IoProcessor will be spawned to process the 
ourgoing and incoming messages.

IoProcessor are selected by the Connector and Acceptor to process the requests.



--
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com


Confidentiality note:
The information in this email and any attachment may contain confidential and 
proprietary information of Heidelberger Druckmaschinen AG and/or its affiliates 
and may be privileged or otherwise protected from disclosure. If you are not 
the intended recipient, you are hereby notified that any review, reliance or 
distribution by others or forwarding without express permission is strictly 
prohibited and may cause liability. In case you have received this message due 
to an error in transmission, we kindly ask you to notify the sender immediately 
and to delete this email and any attachment from your system.


Re: AW: AW: NioSocketConnector/NioSocketAcceptor

2013-08-15 Thread Emmanuel Lécharny
Le 8/15/13 5:13 PM, Simo Chiegang, Boris Arthur RD-P8.1 a écrit :
 Ok that  means, when  I write new NioSocketConnector(), the number of threads 
 to use isn't no limited. If I give a a processorCount (may be 2 ), I will 
 limit the number of threads to 2. I'm wright?

Yes.

If you don't provide any value, the number of IoProcessor will be Nb
Core + 1.

usually, it's enough. If you need more, you can add an executor in the
filter chain, and use a Pool. But keep in mind that whatever you do, if
you are CPU bound, no matter how many threads you add, you are not going
to have better throughput.

-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com 



Re: AW: AW: NioSocketConnector/NioSocketAcceptor

2013-08-15 Thread Jon V.
Please don't take this the wrong way. The apache Mina site is full of
examples and documentation. That should be your primary source of
information before asking questions on the email list.

Remember, this list covers 5 different projects and your email goes out to
a lot of people.

I am very happy to answer questions that involve things that are not
covered by the docs.
On Aug 15, 2013 11:31 AM, Emmanuel Lécharny elecha...@gmail.com wrote:

 Le 8/15/13 5:13 PM, Simo Chiegang, Boris Arthur RD-P8.1 a écrit :
  Ok that  means, when  I write new NioSocketConnector(), the number of
 threads to use isn't no limited. If I give a a processorCount (may be 2 ),
 I will limit the number of threads to 2. I'm wright?

 Yes.

 If you don't provide any value, the number of IoProcessor will be Nb
 Core + 1.

 usually, it's enough. If you need more, you can add an executor in the
 filter chain, and use a Pool. But keep in mind that whatever you do, if
 you are CPU bound, no matter how many threads you add, you are not going
 to have better throughput.

 --
 Regards,
 Cordialement,
 Emmanuel Lécharny
 www.iktek.com