[
https://issues.apache.org/jira/browse/DIRMINA-681?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12834180#action_12834180
]
Mauritz Lovgren commented on DIRMINA-681:
-----------------------------------------
Ran a new loadtest today (on trunk RC2 revision 909546).
I have removed all home-grown executor filters etc etc to run NioAcceptor with
standard CORE mina defaults only.
8500 clients connecting to one NioAcceptor configured to run using 1 thread
(new NioSocketAcceptor(1)) just to keep things simple.
The clients are all running on a separate machine from the server. 1Gb LAN, but
very small messages and low bandwidth needed for test.
The clients connect and thereafter send a simple IsAlive message upon idle
timeout (120 seconds) and stay connected forever.
The clients are connecting at a rate of about 10 clients per second.
My observations are as follows:
- At startup everyting looks ok with only two MINA threads running, the
NioAcceptor and one NioProcessor.
- As clients log on, the WindowSelectorImpl somehow recons that it needs to
start SelectorThread instances to cope with traffic (?).
After about each 1000 connections, a new selector thread is created.
- The WindowSelectorImpl$SelectorThread instances are linearly causing CPU
overhead after they are created. Before they exist, no extra CPU is seen.
- The profiler claims that the bit of code that is causing the CPU overhead is
within the sun.nio.ch.WindowSelectorImpl$SubSelector.poll0() method which is
called by each SelectorThread.run().
Could MINA somehow be (mis)using the select() in a way that causes this
situation to occur? (E.g. calling it too often, or not handling the select keys
properly etc etc).
And, I wonder if this might be the epoll bug at all?
> Strange CPU peak occuring at fixed interval when several thousand connections
> active
> ------------------------------------------------------------------------------------
>
> Key: DIRMINA-681
> URL: https://issues.apache.org/jira/browse/DIRMINA-681
> Project: MINA
> Issue Type: Task
> Components: Core
> Affects Versions: 2.0.0-M4, 2.0.0-RC1
> Environment: Windows Vista Ultimate 64-bit (on 64-bit Sun JDK
> 1.6.0_18). Intel Core 2 Quad Core Q9300 2,5 GHz, 8 GB RAM
> Reporter: Mauritz Lovgren
> Fix For: 2.0.0
>
> Attachments: screenshot-1.jpg, screenshot-2.jpg, screenshot-3.jpg,
> screenshot-4.jpg
>
>
> Observing strange CPU activity occuring at regular (seemingly fixed) interval
> with no protocol traffic activity.
> See attached window capture of task manager that shows this with 3000 active
> connections.
> Is there some kind of cleanup occuring within MINA core at a predefined
> interval?
> The 3000 connections in the example above connects within 250 seconds. A
> normal situation would be that these connections are established over a
> longer period of time, perhaps spreading the CPU peaks shown above as well,
> flattening the curve.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.