Hi Brice, I had the same issue with Java 1.5 here, but not with Java 1.6. I found several articles in the Web about this issue. It does not seem to occur in simple select use cases, if keys get registered and unregistered frequently, the error seems to occur within the JDK.
As a workaround I tried to detect a select without active key and then do a sleep. But since that would decrease overall performance I did not implement such a workaround. If you are bound to a JDK with that NIO error, you should consider implementing such a sleep to reduce CPU load. Best regards, Frank On 03.03.2010 11:35, Brice Fines wrote: > Hi Frank, > > I updated my environment, I am now running our app in WAS 6.1.0.29 (fix > pack 29, the last one available). > I also updated the associated JVM (Service Release 11, the one for fix > pack 29): > > java version "1.5.0" > Java(TM) 2 Runtime Environment, Standard Edition (build pwi32dev-20091106a > (SR11 > )) > IBM J9 VM (build 2.3, J2RE 1.5.0 IBM J9 2.3 Windows XP x86-32 > j9vmwi3223-2009110 > 4 (JIT enabled) > J9VM - 20091103_45935_lHdSMr > JIT - 20091016_1845_r8 > GC - 20091026_AA) > JCL - 20091106 > > Unfortunately, it does not solve the high CPU usage when sending SNMP > commands. > When opening the TCP connection to send and receive the command, CPU goes > up between 55%-100%; with > org.snmp4j.transport.DefaultTcpTransportMapping$SocketTimeout, it falls > again down to 2%) > I hope the next IBM update will help more. > > Is there a simple way to cause/check a high CPU usage boost related to > java NIO select? > I am trying the Ping example (which use a NIO selector) from > http://java.sun.com/j2se/1.4.2/docs/guide/nio/example/index.html , but the > cpu usage is 0% while running it. > But if I execute the following from a command window, I get a CPU usage > peak while running: > C:\>C:\RAD7\SDP70\runtimes\base_v61\java\bin\java -cp snmp4j-1.11.jar > org.snmp4j > .tools.console.SnmpRequest -c private -v 2c -p SET udp:localhost/161 > "1.3.6.1.2 > .1.1.5.0={s}SNMP4J" > Received response after 2016 millis > Request timed out. > > Regards > _______________________________________________ > SNMP4J mailing list > [email protected] > http://lists.agentpp.org/mailman/listinfo/snmp4j -- AGENT++ http://www.agentpp.com http://www.snmp4j.com http://www.mibexplorer.com http://www.mibdesigner.com _______________________________________________ SNMP4J mailing list [email protected] http://lists.agentpp.org/mailman/listinfo/snmp4j
