Issue Details (XML | Word | Printable)

Key: DIRMINA-204
Type: Bug Bug
Status: Closed Closed
Resolution: Invalid
Priority: Major Major
Assignee: Trustin Lee
Reporter: Simon Temple
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
MINA

Network disconnection (or initial connection) once SocketAcceptor is running causes 100% CPU consumption on Windows

Created: 10/Apr/06 04:36 PM   Updated: 26/Apr/06 03:03 PM
Return to search
Component/s: None
Affects Version/s: 0.9.3
Fix Version/s: None

Time Tracking:
Not Specified

Environment: JDK 1.4.2_07, Windows 2000

Resolution Date: 10/Apr/06 08:28 PM


 Description  « Hide
SocketAcceptorDelegate Thread appears to be skipping the Thread.Sleep() because the interrupted attribute of the Thread is set because the selector operation dropped through... I think ;-)

"SocketAcceptor-0" prio=5 tid=0x1784FCD0 nid=0x92c runnable [1802f000..1802fd88]

at java.lang.Thread.isInterrupted(Native Method)
at java.lang.Thread.isInterrupted(Thread.java:771)
at java.nio.channels.spi.AbstractSelector.begin(AbstractSelector.java:198)
at sun.nio.ch.WindowsSelectorImpl.doSelect(WindowsSelectorImpl.java:125)
at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:62)
- locked <040E09F0> (a sun.nio.ch.SelectorImpl$Lock)
at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:67)
at org.apache.mina.transport.socket.nio.support.SocketAcceptorDelegate$Worker.run(SocketAcceptorDelegate.java:326)



 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Simon Temple added a comment - 10/Apr/06 06:15 PM
Apologies... this appears to be a problem when running Java 1.4.1

When running 1.4.2_07 we see very low CPU utilisation when the network is disabled and re-enabled.

I'd guess that the JDK 1.4.1 implementation of poll() spins out of control and 1.4.2 does not:

at sun.nio.ch.WindowsSelectorImpl$SubSelector.poll0(Native Method)
at sun.nio.ch.WindowsSelectorImpl$SubSelector.poll(WindowsSelectorImpl.java:262)
at sun.nio.ch.WindowsSelectorImpl$SubSelector.access$400(WindowsSelectorImpl.java:244)
at sun.nio.ch.WindowsSelectorImpl.doSelect(WindowsSelectorImpl.java:127)
at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:62)

If anyone can educate me about this I'd be pleased to hear from them.

TIA

Simon Temple added a comment - 10/Apr/06 06:51 PM
Not a bug, please close this call.

Trustin Lee added a comment - 10/Apr/06 08:28 PM
It is not our bug but JDK 1.4.1's bug. Thank you for investigating on this issue for us, Simon!

Norval Hope added a comment - 26/Apr/06 12:06 PM
Confirmed against ApacheDS 1.0 RC1 (refer http://issues.apache.org/jira/browse/DIRSERVER-608 ) that the problem went away when upgraded to JDK 1.4.2_11

Trustin Lee added a comment - 26/Apr/06 12:16 PM
Please close this issue, Simon.

Simon Temple added a comment - 26/Apr/06 03:03 PM
Closed as requested