Class LocalDistributor
java.lang.Object
org.openqa.selenium.grid.distributor.Distributor
org.openqa.selenium.grid.distributor.local.LocalDistributor
- All Implemented Interfaces:
AutoCloseable
,Predicate<org.openqa.selenium.remote.http.HttpRequest>
,org.openqa.selenium.remote.http.HttpHandler
,org.openqa.selenium.remote.http.Routable
,HasReadyState
-
Constructor Summary
ConstructorDescriptionLocalDistributor
(org.openqa.selenium.remote.tracing.Tracer tracer, EventBus bus, org.openqa.selenium.remote.http.HttpClient.Factory clientFactory, SessionMap sessions, NewSessionQueue sessionQueue, SlotSelector slotSelector, Secret registrationSecret, Duration healthcheckInterval, boolean rejectUnsupportedCaps, Duration sessionRequestRetryInterval, int newSessionThreadPoolSize, SlotMatcher slotMatcher) -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
static Distributor
boolean
int
protected Set<NodeStatus>
long
int
protected Node
getNodeFromURI
(URI uri) long
boolean
isReady()
org.openqa.selenium.internal.Either<org.openqa.selenium.SessionNotCreatedException,
CreateSessionResponse> newSession
(SessionRequest request) void
refresh()
void
Methods inherited from class org.openqa.selenium.grid.distributor.Distributor
execute, matches, test
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.openqa.selenium.remote.http.Routable
with
-
Constructor Details
-
LocalDistributor
public LocalDistributor(org.openqa.selenium.remote.tracing.Tracer tracer, EventBus bus, org.openqa.selenium.remote.http.HttpClient.Factory clientFactory, SessionMap sessions, NewSessionQueue sessionQueue, SlotSelector slotSelector, Secret registrationSecret, Duration healthcheckInterval, boolean rejectUnsupportedCaps, Duration sessionRequestRetryInterval, int newSessionThreadPoolSize, SlotMatcher slotMatcher)
-
-
Method Details
-
create
-
isReady
public boolean isReady()- Specified by:
isReady
in interfaceHasReadyState
-
add
- Specified by:
add
in classDistributor
-
drain
- Specified by:
drain
in classDistributor
-
remove
- Specified by:
remove
in classDistributor
-
getStatus
- Specified by:
getStatus
in classDistributor
-
refresh
@Beta public void refresh() -
getAvailableNodes
-
newSession
public org.openqa.selenium.internal.Either<org.openqa.selenium.SessionNotCreatedException,CreateSessionResponse> newSession(SessionRequest request) throws org.openqa.selenium.SessionNotCreatedException - Specified by:
newSession
in classDistributor
- Throws:
org.openqa.selenium.SessionNotCreatedException
-
getUpNodeCount
public long getUpNodeCount() -
getDownNodeCount
public long getDownNodeCount() -
getActiveSlots
public int getActiveSlots() -
getIdleSlots
public int getIdleSlots() -
close
public void close()- Specified by:
close
in interfaceAutoCloseable
-
getNodeFromURI
-