Closed hnestorova closed 3 years ago
grid example state during the tests run
Thank you for providing the details. I have attempted to re-create the issue with a Hub and a Node with --max-sessions 1
option having Chrome and Edge capabilities. I am unable to reproduce the scenario and have not come across I/O exception (java.net.SocketException) or java.net.BindExceptioncaught
after multiple attempts. I would suggest please try using the latest beta release https://github.com/SeleniumHQ/selenium/releases/tag/selenium-4.0.0-beta-1 and check if the issue still persists.
I will close this as we verified that it is not happening with beta-1
. If you still have this issue, we'd be happy to reopen this and check again.
Hi @diemol and @pujagani
I checked this today with the beta-1 release and it got reproduced. Please, let me know how we could add some debug logs or smth that will help you identofy the cause 15:06:02 [testng] - I/O exception (java.net.SocketException) caught when processing request to {}->http://PRIVATE:4447: No buffer space available (maximum connections reached?): connect 15:06:02 [testng] - Retrying request to {}->PRIVATE:4447
Thank you for checking again and providing the feedback. I am attempting again to re-create the issue. I am running the tests on MacOS. I have created a test suite similar to the testng.xml file configuration shared in the bug report. I ran the tests for about 45 mins a couple of times, but however, I am unable to re-create the issue. Did you face this issue in 4.0.0-Alpha-7 as well? The reason I ask is, in Beta-1, we create a new instance of AsyncHttpClient every time instead of a global instance. Each instance will have its own connection pool and thread groups. I suspect that might be causing issues. Creating such new connections could be interlinked to the ephemeral port issue faced in Windows https://docs.microsoft.com/en-us/windows/client-management/troubleshoot-tcpip-port-exhaust. We have currently switched back to using a single global instance off AsyncHttpClient thanks to changes made by Diego. To help further re-create the issue, I would appreciate it if you could share a sample test/test suite similar to the tests you have to reproduce this. Thank you!
Hi @pujagani
Thank you for your answer. No, we do not have the issue with 4.0.0-Alpha-7. As I have some limitations as to what i can provide as example code, will it be possible for you to provide a selenium server standalone jar which includes the switch to a single global instance off AsyncHttpClient so that i can check if with it we will still have the issue?
Thanks
@hnestorova, I just did a prerelease and you can grab the jar here https://github.com/seleniumhq/docker-selenium/tree/beta-jars
@diemol thanks! I will test it and post an update
Hi @diemol , I tried it but when i try to add nodes to the grid there is some problem. Unfortunately, the console closes quite fast so I cannot see the exact problem - there is some message regarding ports - see attached screenshot 1 For the grid ui see screenshot 2 Please, let me know if you know what the problem is. My setup is: HUB start C:/"Program Files"/Java/jdk-11.0.9+11/bin/java -jar selenium-server-4.0.0-prerelease-beta-1-aadc2039d7.jar hub --port 4452 --publish-events tcp://HUB_IP:4455 --subscribe-events tcp://HUB_IP:4456
Node start C:/"Program Files"/Java/jdk-11.0.9+11/bin/java -jar selenium-server-4.0.0-prerelease-beta-1-aadc2039d7
.jar node --detect-drivers true -I "chrome" -I "edge" -I "internet explorer" --publish-events tcp://HUB_IP:4455 --subscribe-events tcp://HUB_IP:4456 --max-sessions 1
That was my bad, I just uploaded a new jar with a fix. https://github.com/SeleniumHQ/docker-selenium/tree/beta-jars
okay, i will check it tomorrow and let you know, thank you
Hi @diemol Now i get some other message - see attached screenshot
and i tried with --log-level ALL and got the below output prior to the console being closed
What are the exact commands you are trying?
HUB start C:/"Program Files"/Java/jdk-11.0.9+11/bin/java -jar selenium-server-4.0.0-prerelease-beta-2-aadc2039d7.jar hub --port 4452 --log-level ALL --publish-events tcp://HUB_IP:4455 --subscribe-events tcp://HUB_IP:4456
console log:
16:35:27.032 FINER [Repository.addMBean] - name = java.lang:name=G1 Old Generati
on,type=GarbageCollector
16:35:27.032 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object java.lang:name=G1 Old Generation,type=GarbageColl
ector
16:35:27.032 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered java.lang:name=G1 Old Generation,type=GarbageCollector
16:35:27.048 FINER [StandardMBean.getMBeanInfo] - Building MBeanInfo for sun.man
agement.ManagementFactoryHelper$1
16:35:27.048 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = java.nio:name=mapped,type=BufferPool
16:35:27.048 FINER [Repository.addMBean] - name = java.nio:name=mapped,type=Buff
erPool
16:35:27.048 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object java.nio:name=mapped,type=BufferPool
16:35:27.048 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered java.nio:name=mapped,type=BufferPool
16:35:27.048 FINER [StandardMBean.getMBeanInfo] - Building MBeanInfo for sun.man
agement.ManagementFactoryHelper$1
16:35:27.048 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = java.nio:name=direct,type=BufferPool
16:35:27.048 FINER [Repository.addMBean] - name = java.nio:name=direct,type=Buff
erPool
16:35:27.048 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object java.nio:name=direct,type=BufferPool
16:35:27.048 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered java.nio:name=direct,type=BufferPool
16:35:27.063 FINER [StandardMBean.getMBeanInfo] - Building MBeanInfo for com.sun
.management.internal.HotSpotDiagnostic
16:35:27.063 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = com.sun.management:type=HotSpotDiagnostic
16:35:27.063 FINER [Repository.addMBean] - name = com.sun.management:type=HotSpo
tDiagnostic
16:35:27.063 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object com.sun.management:type=HotSpotDiagnostic
16:35:27.063 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered com.sun.management:type=HotSpotDiagnostic
16:35:27.063 FINER [StandardMBean.getMBeanInfo] - Building MBeanInfo for jdk.man
agement.jfr.FlightRecorderMXBeanImpl
16:35:27.079 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = jdk.management.jfr:type=FlightRecorder
16:35:27.079 FINER [Repository.addMBean] - name = jdk.management.jfr:type=Flight
Recorder
16:35:27.079 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object jdk.management.jfr:type=FlightRecorder
16:35:27.079 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered jdk.management.jfr:type=FlightRecorder
16:35:27.095 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = org.seleniumhq.grid:type=Config,name=BaseServerConfig
16:35:27.095 FINER [Repository.addMBean] - name = org.seleniumhq.grid:type=Confi
g,name=BaseServerConfig
16:35:27.095 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object org.seleniumhq.grid:name=BaseServerConfig,type=Co
nfig
16:35:27.095 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered org.seleniumhq.grid:type=Config,name=BaseServerConfig
16:35:27.173 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = org.seleniumhq.grid:type=Config,name=NewSessionQueueConfig
16:35:27.173 FINER [Repository.addMBean] - name = org.seleniumhq.grid:type=Confi
g,name=NewSessionQueueConfig
16:35:27.188 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object org.seleniumhq.grid:name=NewSessionQueueConfig,ty
pe=Config
16:35:27.188 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered org.seleniumhq.grid:type=Config,name=NewSessionQueueConfig
16:35:27.188 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = org.seleniumhq.grid:type=SessionQueue,name=LocalSessionQueue
16:35:27.188 FINER [Repository.addMBean] - name = org.seleniumhq.grid:type=Sessi
onQueue,name=LocalSessionQueue
16:35:27.188 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object org.seleniumhq.grid:name=LocalSessionQueue,type=S
essionQueue
16:35:27.188 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered org.seleniumhq.grid:type=SessionQueue,name=LocalSessionQueue
16:35:28.173 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = org.seleniumhq.grid:type=Config,name=BaseServerConfig
16:35:28.173 FINER [Repository.addMBean] - name = org.seleniumhq.grid:type=Confi
g,name=BaseServerConfig
16:35:28.204 DEBUG [MultithreadEventLoopGroup.<clinit>] - -Dio.netty.eventLoopTh
reads: 4
16:35:28.220 DEBUG [InternalThreadLocalMap.<clinit>] - -Dio.netty.threadLocalMap
.stringBuilder.initialSize: 1024
16:35:28.220 DEBUG [InternalThreadLocalMap.<clinit>] - -Dio.netty.threadLocalMap
.stringBuilder.maxSize: 4096
16:35:28.220 DEBUG [NioEventLoop.<clinit>] - -Dio.netty.noKeySetOptimization: fa
lse
16:35:28.235 DEBUG [NioEventLoop.<clinit>] - -Dio.netty.selectorAutoRebuildThres
hold: 512
16:35:28.251 DEBUG [PlatformDependent.isWindows0] - Platform: Windows
16:35:28.251 DEBUG [PlatformDependent0.explicitNoUnsafeCause0] - -Dio.netty.noUn
safe: false
16:35:28.251 DEBUG [PlatformDependent0.javaVersion0] - Java version: 11
16:35:28.251 DEBUG [PlatformDependent0.<clinit>] - sun.misc.Unsafe.theUnsafe: av
ailable
16:35:28.251 DEBUG [PlatformDependent0.<clinit>] - sun.misc.Unsafe.copyMemory: a
vailable
16:35:28.251 DEBUG [PlatformDependent0.<clinit>] - java.nio.Buffer.address: avai
lable
16:35:28.251 DEBUG [PlatformDependent0.<clinit>] - direct buffer constructor: un
available
java.lang.UnsupportedOperationException: Reflective setAccessible(true) disabled
at io.netty.util.internal.ReflectionUtil.trySetAccessible(ReflectionUtil
.java:31)
at io.netty.util.internal.PlatformDependent0$4.run(PlatformDependent0.ja
va:238)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at io.netty.util.internal.PlatformDependent0.<clinit>(PlatformDependent0
.java:232)
at io.netty.util.internal.PlatformDependent.isAndroid(PlatformDependent.
java:293)
at io.netty.util.internal.PlatformDependent.<clinit>(PlatformDependent.j
ava:92)
at io.netty.channel.nio.NioEventLoop.newTaskQueue0(NioEventLoop.java:279
)
at io.netty.channel.nio.NioEventLoop.newTaskQueue(NioEventLoop.java:150)
at io.netty.channel.nio.NioEventLoop.<init>(NioEventLoop.java:138)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:146)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:37)
at io.netty.util.concurrent.MultithreadEventExecutorGroup.<init>(Multith
readEventExecutorGroup.java:84)
at io.netty.util.concurrent.MultithreadEventExecutorGroup.<init>(Multith
readEventExecutorGroup.java:58)
at io.netty.channel.MultithreadEventLoopGroup.<init>(MultithreadEventLoo
pGroup.java:52)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
96)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
91)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
72)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
52)
at org.openqa.selenium.netty.server.NettyServer.<init>(NettyServer.java:
102)
at org.openqa.selenium.grid.TemplateGridServerCommand.asServer(TemplateG
ridServerCommand.java:43)
at org.openqa.selenium.grid.commands.Hub.execute(Hub.java:193)
at org.openqa.selenium.grid.TemplateGridCommand.lambda$configure$5(Templ
ateGridCommand.java:129)
at org.openqa.selenium.grid.Main.launch(Main.java:83)
at org.openqa.selenium.grid.Main.go(Main.java:57)
at org.openqa.selenium.grid.Main.main(Main.java:42)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Nativ
e Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Native
MethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(De
legatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.openqa.selenium.grid.Bootstrap.runMain(Bootstrap.java:77)
at org.openqa.selenium.grid.Bootstrap.main(Bootstrap.java:70)
16:35:28.266 DEBUG [PlatformDependent0.<clinit>] - java.nio.Bits.unaligned: avai
lable, true
16:35:28.266 DEBUG [PlatformDependent0.<clinit>] - jdk.internal.misc.Unsafe.allo
cateUninitializedArray(int): unavailable
java.lang.IllegalAccessException: class io.netty.util.internal.PlatformDependent
0$6 cannot access class jdk.internal.misc.Unsafe (in module java.base) because m
odule java.base does not export jdk.internal.misc to unnamed module @6ad11a56
at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(R
eflection.java:361)
at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleOb
ject.java:591)
at java.base/java.lang.reflect.Method.invoke(Method.java:558)
at io.netty.util.internal.PlatformDependent0$6.run(PlatformDependent0.ja
va:352)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at io.netty.util.internal.PlatformDependent0.<clinit>(PlatformDependent0
.java:343)
at io.netty.util.internal.PlatformDependent.isAndroid(PlatformDependent.
java:293)
at io.netty.util.internal.PlatformDependent.<clinit>(PlatformDependent.j
ava:92)
at io.netty.channel.nio.NioEventLoop.newTaskQueue0(NioEventLoop.java:279
)
at io.netty.channel.nio.NioEventLoop.newTaskQueue(NioEventLoop.java:150)
at io.netty.channel.nio.NioEventLoop.<init>(NioEventLoop.java:138)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:146)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:37)
at io.netty.util.concurrent.MultithreadEventExecutorGroup.<init>(Multith
readEventExecutorGroup.java:84)
at io.netty.util.concurrent.MultithreadEventExecutorGroup.<init>(Multith
readEventExecutorGroup.java:58)
at io.netty.channel.MultithreadEventLoopGroup.<init>(MultithreadEventLoo
pGroup.java:52)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
96)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
91)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
72)
at io.netty.channel.nio.NioEventLoopGroup.<init>(NioEventLoopGroup.java:
52)
at org.openqa.selenium.netty.server.NettyServer.<init>(NettyServer.java:
102)
at org.openqa.selenium.grid.TemplateGridServerCommand.asServer(TemplateG
ridServerCommand.java:43)
at org.openqa.selenium.grid.commands.Hub.execute(Hub.java:193)
at org.openqa.selenium.grid.TemplateGridCommand.lambda$configure$5(Templ
ateGridCommand.java:129)
at org.openqa.selenium.grid.Main.launch(Main.java:83)
at org.openqa.selenium.grid.Main.go(Main.java:57)
at org.openqa.selenium.grid.Main.main(Main.java:42)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Nativ
e Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Native
MethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(De
legatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.openqa.selenium.grid.Bootstrap.runMain(Bootstrap.java:77)
at org.openqa.selenium.grid.Bootstrap.main(Bootstrap.java:70)
16:35:28.282 DEBUG [PlatformDependent0.<clinit>] - java.nio.DirectByteBuffer.<in
it>(long, int): unavailable
16:35:28.282 DEBUG [PlatformDependent.unsafeUnavailabilityCause0] - sun.misc.Uns
afe: available
16:35:28.282 DEBUG [PlatformDependent.maxDirectMemory0] - maxDirectMemory: 10737
41824 bytes (maybe)
16:35:28.282 DEBUG [PlatformDependent.tmpdir0] - -Dio.netty.tmpdir: C:\Users\qa\
AppData\Local\Temp (java.io.tmpdir)
16:35:28.282 DEBUG [PlatformDependent.bitMode0] - -Dio.netty.bitMode: 64 (sun.ar
ch.data.model)
16:35:28.282 DEBUG [PlatformDependent.<clinit>] - -Dio.netty.maxDirectMemory: -1
bytes
16:35:28.282 DEBUG [PlatformDependent.<clinit>] - -Dio.netty.uninitializedArrayA
llocationThreshold: -1
16:35:28.282 DEBUG [CleanerJava9.<clinit>] - java.nio.ByteBuffer.cleaner(): avai
lable
16:35:28.282 DEBUG [PlatformDependent.<clinit>] - -Dio.netty.noPreferDirect: fal
se
16:35:28.298 DEBUG [PlatformDependent$Mpsc.<clinit>] - org.jctools-core.MpscChun
kedArrayQueue: available
16:35:28.313 FINEST [NioEventLoop.openSelector] - instrumented a special java.ut
il.Set into: sun.nio.ch.WindowsSelectorImpl@71a3a190
16:35:28.313 FINEST [NioEventLoop.openSelector] - instrumented a special java.ut
il.Set into: sun.nio.ch.WindowsSelectorImpl@5eeedb60
16:35:28.313 FINEST [NioEventLoop.openSelector] - instrumented a special java.ut
il.Set into: sun.nio.ch.WindowsSelectorImpl@40021799
16:35:28.313 FINEST [NioEventLoop.openSelector] - instrumented a special java.ut
il.Set into: sun.nio.ch.WindowsSelectorImpl@4a1c0752
16:35:28.313 FINEST [NioEventLoop.openSelector] - instrumented a special java.ut
il.Set into: sun.nio.ch.WindowsSelectorImpl@332f25c8
16:35:28.423 DEBUG [DefaultChannelId.<clinit>] - -Dio.netty.processId: 1932 (aut
o-detected)
16:35:28.423 DEBUG [NetUtil.<clinit>] - -Djava.net.preferIPv4Stack: false
16:35:28.423 DEBUG [NetUtil.<clinit>] - -Djava.net.preferIPv6Addresses: false
16:35:28.454 DEBUG [NetUtilInitializations.determineLoopback] - Loopback interfa
ce: lo (Software Loopback Interface 1, 127.0.0.1)
16:35:28.454 DEBUG [NetUtil$1.run] - Failed to get SOMAXCONN from sysctl and fil
e \proc\sys\net\core\somaxconn. Default: 200
16:35:28.501 DEBUG [DefaultChannelId.<clinit>] - -Dio.netty.machineId: 00:50:56:
ff:fe:bf:2a:2c (auto-detected)
16:35:28.516 DEBUG [ResourceLeakDetector.<clinit>] - -Dio.netty.leakDetection.le
vel: simple
16:35:28.516 DEBUG [ResourceLeakDetector.<clinit>] - -Dio.netty.leakDetection.ta
rgetRecords: 4
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.numH
eapArenas: 4
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.numD
irectArenas: 4
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.page
Size: 8192
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.maxO
rder: 11
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.chun
kSize: 16777216
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.smal
lCacheSize: 256
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.norm
alCacheSize: 64
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.maxC
achedBufferCapacity: 32768
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.cach
eTrimInterval: 8192
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.cach
eTrimIntervalMillis: 0
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.useC
acheForAllThreads: true
16:35:28.548 DEBUG [PooledByteBufAllocator.<clinit>] - -Dio.netty.allocator.maxC
achedByteBuffersPerChunk: 1023
16:35:28.563 DEBUG [ByteBufUtil.<clinit>] - -Dio.netty.allocator.type: pooled
16:35:28.563 DEBUG [ByteBufUtil.<clinit>] - -Dio.netty.threadLocalDirectBufferSi
ze: 0
16:35:28.563 DEBUG [ByteBufUtil.<clinit>] - -Dio.netty.maxThreadLocalCharBufferS
ize: 16384
16:35:28.595 DEBUG [LoggingHandler.channelRegistered] - [id: 0xd2f99078] REGISTE
RED
16:35:28.595 DEBUG [LoggingHandler.bind] - [id: 0xd2f99078] BIND: 0.0.0.0/0.0.0.
0:4452
16:35:28.595 DEBUG [LoggingHandler.channelActive] - [id: 0xd2f99078, L:/0:0:0:0:
0:0:0:0:4452] ACTIVE
16:35:28.610 INFO [Hub.execute] - Started Selenium Hub 4.0.0-beta-2 (revision aa
dc2039d7): http://HUB_IP:4452
NODE start C:/"Program Files"/Java/jdk-11.0.9+11/bin/java -jar selenium-server-4.0.0-prerelease-beta-2-aadc2039d7.jar node --log-level ALL --detect-drivers true -I "edge" -I "chrome" -I "internet explorer" --publish-events tcp://HUB_IP:4455 --subscribe-events tcp://HUB_IP:4456 --max-sessions 1
Please use this jar https://github.com/SeleniumHQ/docker-selenium/blob/beta-jars/selenium-server-4.0.0-prerelease-beta-2-d8c0d8e262.jar, seems you were still using the one with the error.
@diemol this one worked for hub and node on the same machine with the above commands - see screenshot
However, when i tried to add another VM as a second node using the same node command, i got:
Name = java.nio:name=direct,type=BufferPool
16:58:03.615 FINER [Repository.addMBean] - name = java.nio:name=direct,type=Buff
erPool
16:58:03.615 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object java.nio:name=direct,type=BufferPool
16:58:03.615 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered java.nio:name=direct,type=BufferPool
16:58:03.615 FINER [StandardMBean.getMBeanInfo] - Building MBeanInfo for com.sun
.management.internal.HotSpotDiagnostic
16:58:03.615 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = com.sun.management:type=HotSpotDiagnostic
16:58:03.615 FINER [Repository.addMBean] - name = com.sun.management:type=HotSpo
tDiagnostic
16:58:03.615 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object com.sun.management:type=HotSpotDiagnostic
16:58:03.615 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered com.sun.management:type=HotSpotDiagnostic
16:58:03.630 FINER [StandardMBean.getMBeanInfo] - Building MBeanInfo for jdk.man
agement.jfr.FlightRecorderMXBeanImpl
16:58:03.630 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = jdk.management.jfr:type=FlightRecorder
16:58:03.630 FINER [Repository.addMBean] - name = jdk.management.jfr:type=Flight
Recorder
16:58:03.630 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object jdk.management.jfr:type=FlightRecorder
16:58:03.630 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered jdk.management.jfr:type=FlightRecorder
16:58:03.646 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = org.seleniumhq.grid:type=Config,name=BaseServerConfig
16:58:03.646 FINER [Repository.addMBean] - name = org.seleniumhq.grid:type=Confi
g,name=BaseServerConfig
16:58:03.646 FINER [DefaultMBeanServerInterceptor.registerWithRepository] - Send
create notification of object org.seleniumhq.grid:name=BaseServerConfig,type=Co
nfig
16:58:03.646 FINER [DefaultMBeanServerInterceptor.sendNotification] - JMX.mbean.
registered org.seleniumhq.grid:type=Config,name=BaseServerConfig
16:58:03.740 INFO [NodeServer.createHandlers] - Reporting self as: http://10.44.
16.41:5555
16:58:03.740 FINER [DefaultMBeanServerInterceptor.registerDynamicMBean] - Object
Name = org.seleniumhq.grid:type=Config,name=BaseServerConfig
16:58:03.740 FINER [Repository.addMBean] - name = org.seleniumhq.grid:type=Confi
g,name=BaseServerConfig
16:58:03.927 INFO [NodeOptions.discoverDrivers] - Discovered 3 driver(s)
16:58:03.974 INFO [NodeOptions.report] - Adding Chrome for {"browserName": "chro
me"} 1 times
16:58:03.974 INFO [NodeOptions.report] - Adding Edge for {"browserName": "Micros
oftEdge"} 1 times
16:58:03.974 INFO [NodeOptions.report] - Adding Internet Explorer for {"browserN
ame": "internet explorer"} 1 times
16:58:04.005 INFO [Node.
at io.netty.util.internal.ReflectionUtil.trySetAccessible(ReflectionUtil
.java:31)
at io.netty.util.internal.PlatformDependent0$4.run(PlatformDependent0.ja
va:238)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at io.netty.util.internal.PlatformDependent0.
at io.netty.channel.nio.NioEventLoop.<init>(NioEventLoop.java:138)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:146)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:37)
at io.netty.util.concurrent.MultithreadEventExecutorGroup.
at io.netty.channel.nio.NioEventLoop.<init>(NioEventLoop.java:138)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:146)
at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.jav
a:37)
at io.netty.util.concurrent.MultithreadEventExecutorGroup.
and it works fine with selenium server 4 alpha 7
Thank you, there was indeed a small bug in the cli parsing. I've uploaded a new jar so you can try it out. https://github.com/SeleniumHQ/docker-selenium/blob/beta-jars/selenium-server-4.0.0-prerelease-beta-2-9c138bc189.jar
Hi, I confirm this time the grid was successfully created with 2 nodes I will test the behavior tomorrow to see if the reported in this issue exceptions occur with the new jar and will post an update
Hi @diemol
Our tests have been running for approx 2 hours now and I have not seen the exception yet - i will continue monitoring and comment how it goes with the whole suite
In the begging of the suite run, however, when certain cases failed, the below exception was thrown - do you know what a probable cause could be? I noticed the Edge browser and webdriver versions differ so maybe this is causing some problems 17:09:56 [testng] 2021-03-12 17:09:58 EET (Europe/Helsinki) PRIVATE - QPV2X4-0C.png 17:09:56 [testng] Command: [5c2f026eedbcd84a00564dcb14404717, screenshot {}] 17:09:56 [testng] Capabilities {acceptInsecureCerts: false, browserName: msedge, browserVersion: 89.0.774.45, javascriptEnabled: true, ms:edgeOptions: {debuggerAddress: localhost:62470}, msedge: {msedgedriverVersion: 88.0.705.50 (046db035bf4545..., userDataDir: C:\Users\qa\AppData\Local\T...}, networkConnectionEnabled: false, pageLoadStrategy: normal, platform: WINDOWS, platformName: WINDOWS, proxy: Proxy(), se:cdp: http://PRIVATE:5555/ses..., setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:largeBlob: true, webauthn:virtualAuthenticators: true} 17:09:56 [testng] Session ID: 5c2f026eedbcd84a00564dcb14404717 17:09:56 [testng] at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) 17:09:56 [testng] at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) 17:09:56 [testng] at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) 17:09:56 [testng] at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490) 17:09:56 [testng] at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.createException(W3CHttpResponseCodec.java:195) 17:09:56 [testng] at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:128) 17:09:56 [testng] at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:52) 17:09:56 [testng] at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:187) 17:09:56 [testng] at org.openqa.selenium.remote.TracedCommandExecutor.execute(TracedCommandExecutor.java:39) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:620) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:675) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:679) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.getScreenshotAs(RemoteWebDriver.java:355) 17:09:56 [testng] at PRIAVTE.takeAPicture(PRIAVTE.java:750) 17:09:56 [testng] at PRIVATE.ScreenshotListener.getScreenshot(ScreenshotListener.java:25) 17:09:56 [testng] at PRIVATE.ScreenshotListener.onTestFailure(ScreenshotListener.java:30) 17:09:56 [testng] at org.testng.internal.TestListenerHelper.runTestListeners(TestListenerHelper.java:96) 17:09:56 [testng] at org.testng.internal.TestInvoker.runTestResultListener(TestInvoker.java:220) 17:09:56 [testng] at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:657) 17:09:56 [testng] at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174) 17:09:56 [testng] at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46) 17:09:56 [testng] at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822) 17:09:56 [testng] at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147) 17:09:56 [testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146) 17:09:56 [testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128) 17:09:56 [testng] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) 17:09:56 [testng] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) 17:09:56 [testng] at java.base/java.lang.Thread.run(Thread.java:834) 17:09:56 [testng] org.openqa.selenium.WebDriverException: null value in entry: message=null 17:09:56 [testng] Build info: version: '4.0.0-beta-2', revision: '9c138bc189' 17:09:56 [testng] System info: host: 'PRIVATE', ip: 'PRIVATE', os.name: 'Windows Server 2008 R2', os.arch: 'amd64', os.version: '6.1', java.version: '11.0.9' 17:09:56 [testng] Driver info: org.openqa.selenium.remote.RemoteWebDriver 17:09:56 [testng] Command: [12b7f155baf842a8475e6c15c4cb07f4, screenshot {}] 17:09:56 [testng] Capabilities {acceptInsecureCerts: false, browserName: msedge, browserVersion: 89.0.774.45, javascriptEnabled: true, ms:edgeOptions: {debuggerAddress: localhost:51366}, msedge: {msedgedriverVersion: 88.0.705.50 (046db035bf4545..., userDataDir: C:\Users\qa\AppData\Local\T...}, networkConnectionEnabled: false, pageLoadStrategy: normal, platform: WINDOWS, platformName: WINDOWS, proxy: Proxy(), se:cdp: http://PRIVATE:5555/ses..., setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:largeBlob: true, webauthn:virtualAuthenticators: true} 17:09:56 [testng] Session ID: 12b7f155baf842a8475e6c15c4cb07f4 17:09:56 [testng] at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) 17:09:56 [testng] at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) 17:09:56 [testng] at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) 17:09:56 [testng] at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490) 17:09:56 [testng] at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.createException(W3CHttpResponseCodec.java:195) 17:09:56 [testng] at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:128) 17:09:56 [testng] at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:52) 17:09:56 [testng] at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:187) 17:09:56 [testng] at org.openqa.selenium.remote.TracedCommandExecutor.execute(TracedCommandExecutor.java:39) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:620) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:675) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:679) 17:09:56 [testng] at org.openqa.selenium.remote.RemoteWebDriver.getScreenshotAs(RemoteWebDriver.java:355) 17:09:56 [testng] at PRIVATE.takeAPicture(BaseTest.java:750) 17:09:56 [testng] at PRIVATE.ScreenshotListener.getScreenshot(ScreenshotListener.java:25) 17:09:56 [testng] at PRIVATE.ScreenshotListener.onTestFailure(ScreenshotListener.java:30) 17:09:56 [testng] at org.testng.internal.TestListenerHelper.runTestListeners(TestListenerHelper.java:96) 17:09:56 [testng] at org.testng.internal.TestInvoker.runTestResultListener(TestInvoker.java:220) 17:09:56 [testng] at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:657) 17:09:56 [testng] at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174) 17:09:56 [testng] at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46) 17:09:56 [testng] at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822) 17:09:56 [testng] at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147) 17:09:56 [testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146) 17:09:56 [testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128) 17:09:56 [testng] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) 17:09:56 [testng] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) 17:09:56 [testng] at java.base/java.lang.Thread.run(Thread.java:834) 17:09:56 [testng] org.openqa.selenium.WebDriverException: null value in entry: message=null 17:09:56 [testng] Build info: version: '4.0.0-beta-2', revision: '9c138bc189' 17:09:56 [testng] System info: host: 'PRIVATE', ip: 'PRIVATE', os.name: 'Windows Server 2008 R2', os.arch: 'amd64', os.version: '6.1', java.version: '11.0.9' 17:09:56 [testng] Driver info: org.openqa.selenium.remote.RemoteWebDriver
That stacktrace is similar to one I saw earlier, I fixed that in trunk
and we will do another pre-release next week.
For now, I will close this issue and if the one you are showing on the stacktrace persists, please open a new one. Thank you for the valuable feedback!
🐛 Bug Report
As per https://github.com/SeleniumHQ/selenium/issues/8974#issuecomment-762957299 I tried running my tests from Jenkins with the newest selenium jars. However, after a period of an hour or so after the tests have been started, I start getting either:
06:10:38 [testng] 2021-02-13 06:10:35 EET (Europe/Helsinki) running 'Testc1' on node 'http://NODE_IP:5555' 06:11:08 [testng] - I/O exception (java.net.SocketException) caught when processing request to {}->http://HUB:4447: No buffer space available (maximum connections reached?): connect 06:11:08 [testng] - Retrying request to {}->http://HUB:4447 06:11:08 [testng] - I/O exception (java.net.SocketException) caught when processing request to {}->http://HUB:4447: No buffer space available (maximum connections reached?): connect 06:11:08 [testng] - Retrying request to {}->http://HUB:4447 06:11:08 [testng] - I/O exception (java.net.SocketException) caught when processing request to {}->http://HUB:4447: No buffer space available (maximum connections reached?): connect 06:11:08 [testng] - Retrying request to {}->http://HUB:4447 06:11:44 [testng] 2021-02-13 06:11:40 EET (Europe/Helsinki) running Test227' on node 'http://NODE_IP:5555'
or:
07:34:15 [testng] 2021-02-13 07:34:11 EET (Europe/Helsinki) running 'Test1' on node 'http://NODE_IP:5555' 07:35:00 [testng] - I/O exception (java.net.BindException) caught when processing request to {}->http://HUB:4447: Address already in use: connect 07:35:00 [testng] - Retrying request to {}->http://HUB:4447 07:35:28 [testng] Feb 13, 2021 7:35:26 AM org.openqa.selenium.remote.ProtocolHandshake createSession 07:35:28 [testng] INFO: Detected dialect: W3C 07:35:35 [testng] Feb 13, 2021 7:35:33 AM org.openqa.selenium.remote.ProtocolHandshake createSession 07:35:35 [testng] INFO: Detected dialect: W3C 07:36:34 [testng] Feb 13, 2021 7:36:32 AM org.openqa.selenium.remote.ProtocolHandshake createSession 07:36:34 [testng] INFO: Detected dialect: W3C 07:37:01 [testng] 07:37:01 [testng] =============================================== 07:37:01 [testng] Failed suite [Tests] 07:37:01 [testng] Total tests run: 626, Passes: 75, Failures: 14, Skips: 537
To Reproduce
My setup is the following - I have several grids with hubs listening to different ports on a single Virtual Machine . For a single grid I would have: Hub start C:/"Program Files"/Java/jdk-11.0.2/bin/java -jar selenium-server-beta.jar hub --port 4452 --publish-events tcp://HUB_IP:4455 --subscribe-events tcp://HUB_IP:4456
Node start C:/"Program Files"/Java/jdk-11.0.2/bin/java -jar selenium-server-beta.jar node --detect-drivers true -I "chrome" -I "edge" -I "internet explorer" --publish-events tcp://HUB_IP:4455 --subscribe-events tcp://HUB_IP:4456 --max-sessions 1
TestNG xml - note that for some tags we have classes count greater than threads count and we also have parallel set to classes. I tried adding more test tags so that number of classes in a tag does not exceed the available nodes (problem originally handled in https://github.com/SeleniumHQ/selenium/issues/8974), but this did not resolve the problem
`<!DOCTYPE suite SYSTEM "https://testng.org/testng-1.0.dtd">
`
Environment
OS: Windows 7 Browser: Edge, Chrome Edge Browser version: 88.0.705.63 Edge Browser Driver version: 88.0.705.50 Browser version: Chrome 88.0.4324.146 Chrome Browser Driver version: 88.0.4324.96 Selenium Grid version : Grid 4 (selenium-server-4.0.0-prerelease-beta-1-0f2429af7a.jar)