Class NewSessionQueue
java.lang.Object
org.openqa.selenium.grid.sessionqueue.NewSessionQueue
- All Implemented Interfaces:
HttpHandler
,Routable
,HasReadyState
- Direct Known Subclasses:
LocalNewSessionQueue
,RemoteNewSessionQueue
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
NewSessionQueue
(Tracer tracer, Secret registrationSecret) -
Method Summary
Modifier and TypeMethodDescriptionabstract HttpResponse
addToQueue
(SessionRequest request) abstract int
abstract boolean
complete
(RequestId reqId, Either<SessionNotCreatedException, CreateSessionResponse> result) execute
(HttpRequest req) abstract List<SessionRequest>
getNextAvailable
(Map<Capabilities, Long> stereotypes) abstract List<SessionRequestCapability>
boolean
matches
(HttpRequest req) abstract boolean
A fast-path to detect if the queue is empty, returns false if there is no fast-path available.abstract Optional<SessionRequest>
abstract boolean
retryAddToQueue
(SessionRequest request) 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.status.HasReadyState
isReady
-
Field Details
-
tracer
-
-
Constructor Details
-
NewSessionQueue
-
-
Method Details
-
peekEmpty
public abstract boolean peekEmpty()A fast-path to detect if the queue is empty, returns false if there is no fast-path available.- Returns:
- true if the queue is empty, false if it is not empty or unknown
-
addToQueue
-
retryAddToQueue
-
remove
-
getNextAvailable
-
complete
public abstract boolean complete(RequestId reqId, Either<SessionNotCreatedException, CreateSessionResponse> result) -
clearQueue
public abstract int clearQueue() -
getQueueContents
-
matches
-
execute
- Specified by:
execute
in interfaceHttpHandler
-