Class LocalDistributor
- java.lang.Object
-
- org.openqa.selenium.grid.distributor.Distributor
-
- org.openqa.selenium.grid.distributor.local.LocalDistributor
-
- All Implemented Interfaces:
java.util.function.Predicate<org.openqa.selenium.remote.http.HttpRequest>
,org.openqa.selenium.remote.http.HttpHandler
,org.openqa.selenium.remote.http.Routable
,HasReadyState
public class LocalDistributor extends Distributor
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
LocalDistributor.NewSessionRunnable
-
Constructor Summary
Constructors Constructor Description LocalDistributor(org.openqa.selenium.remote.tracing.Tracer tracer, EventBus bus, org.openqa.selenium.remote.http.HttpClient.Factory clientFactory, SessionMap sessions, NewSessionQueuer sessionRequests, Secret registrationSecret, java.time.Duration healthcheckInterval)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description LocalDistributor
add(Node node)
void
callExecutorShutdown()
static Distributor
create(Config config)
boolean
drain(NodeId nodeId)
protected java.util.Set<NodeStatus>
getAvailableNodes()
DistributorStatus
getStatus()
boolean
isReady()
void
refresh()
void
remove(NodeId nodeId)
protected org.openqa.selenium.internal.Either<org.openqa.selenium.SessionNotCreatedException,CreateSessionResponse>
reserve(SlotId slotId, CreateSessionRequest request)
-
Methods inherited from class org.openqa.selenium.grid.distributor.Distributor
execute, matches, newSession, test
-
-
-
-
Constructor Detail
-
LocalDistributor
public LocalDistributor(org.openqa.selenium.remote.tracing.Tracer tracer, EventBus bus, org.openqa.selenium.remote.http.HttpClient.Factory clientFactory, SessionMap sessions, NewSessionQueuer sessionRequests, Secret registrationSecret, java.time.Duration healthcheckInterval)
-
-
Method Detail
-
create
public static Distributor create(Config config)
-
isReady
public boolean isReady()
-
add
public LocalDistributor add(Node node)
- Specified by:
add
in classDistributor
-
drain
public boolean drain(NodeId nodeId)
- Specified by:
drain
in classDistributor
-
remove
public void remove(NodeId nodeId)
- Specified by:
remove
in classDistributor
-
getStatus
public DistributorStatus getStatus()
- Specified by:
getStatus
in classDistributor
-
refresh
@Beta public void refresh()
-
getAvailableNodes
protected java.util.Set<NodeStatus> getAvailableNodes()
- Specified by:
getAvailableNodes
in classDistributor
-
reserve
protected org.openqa.selenium.internal.Either<org.openqa.selenium.SessionNotCreatedException,CreateSessionResponse> reserve(SlotId slotId, CreateSessionRequest request)
- Specified by:
reserve
in classDistributor
-
callExecutorShutdown
public void callExecutorShutdown()
-
-