File tree Expand file tree Collapse file tree
java/server/src/org/openqa/selenium/grid/distributor/local Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -97,6 +97,7 @@ public class LocalDistributor extends Distributor {
9797 private static final Json JSON = new Json ();
9898 private static final Logger LOG = Logger .getLogger ("Selenium Distributor (Local)" );
9999 private final ReadWriteLock lock = new ReentrantReadWriteLock (/* fair */ true );
100+ private final HostSelector hostSelector = new DefaultHostSelector ();
100101 private final Set <Host > hosts = new HashSet <>();
101102 private final Tracer tracer ;
102103 private final EventBus bus ;
@@ -180,7 +181,6 @@ public CreateSessionResponse newSession(HttpRequest request)
180181 Lock writeLock = this .lock .writeLock ();
181182 writeLock .lock ();
182183 try {
183- HostSelector hostSelector = new DefaultHostSelector ();
184184 // Find a host that supports the capabilities present in the new session
185185 Optional <Host > selectedHost = hostSelector .selectHost (firstRequest .getCapabilities (), this .hosts );
186186 // Reserve some space for this session
You can’t perform that action at this time.
0 commit comments