|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.openqa.grid.internal.RemoteProxy
org.openqa.grid.selenium.proxy.DefaultRemoteProxy
public class DefaultRemoteProxy
Default remote proxy for selenium, handling both selenium1 and webdriver requests.
| Field Summary |
|---|
| Fields inherited from class org.openqa.grid.internal.RemoteProxy |
|---|
remoteHost |
| Constructor Summary | |
|---|---|
DefaultRemoteProxy(RegistrationRequest request,
Registry registry)
|
|
| Method Summary | |
|---|---|
void |
addNewEvent(RemoteException event)
Allow to record when something important about the remote state is detected. |
void |
afterCommand(TestSession session,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Executed just before the forwards returns. |
void |
afterSession(TestSession session)
Will be run after the last command is forwarded, but before the proxy slot is released. |
void |
beforeCommand(TestSession session,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Executed before the hub forwards the request. |
void |
beforeRelease(TestSession session)
Gives a chance to clean the resources on the remote when the session has timed out. |
void |
beforeSession(TestSession session)
The client shouldn't have to care where firefox is installed as long as the correct version is launched, however with webdriver the binary location is specified in the desiredCapability, making it the responsibility of the person running the test. |
HtmlRenderer |
getHtmlRender()
|
TestSession |
getNewSession(java.util.Map<java.lang.String,java.lang.Object> requestedCapability)
overwrites the session allocation to discard the proxy that are down. |
boolean |
isAlive()
|
boolean |
isDown()
|
void |
onEvent(java.util.List<RemoteException> events,
RemoteException lastInserted)
Allow to process the list of all the events that were detected on this Remote so far. |
void |
startPolling()
start/restart the polling for the remote proxy. |
void |
stopPolling()
put the polling on hold. |
void |
teardown()
|
| Methods inherited from class org.openqa.grid.internal.RemoteProxy |
|---|
compareTo, equals, getCapabilityHelper, getConfig, getHttpClientFactory, getId, getMaxNumberOfConcurrentTestSessions, getNewInstance, getOriginalRegistrationRequest, getRegistry, getRemoteHost, getStatus, getTestSlots, getTimeOut, getTotalUsed, hashCode, isBusy, setCapabilityHelper, setupTimeoutListener, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultRemoteProxy(RegistrationRequest request,
Registry registry)
| Method Detail |
|---|
public void beforeRelease(TestSession session)
TimeoutListener
beforeRelease in interface TimeoutListener
public void afterCommand(TestSession session,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
CommandListener
afterCommand in interface CommandListener
public void beforeCommand(TestSession session,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
CommandListener
beforeCommand in interface CommandListenerpublic HtmlRenderer getHtmlRender()
getHtmlRender in class RemoteProxypublic boolean isAlive()
public void startPolling()
SelfHealingProxy
startPolling in interface SelfHealingProxypublic void stopPolling()
SelfHealingProxy
stopPolling in interface SelfHealingProxypublic void addNewEvent(RemoteException event)
SelfHealingProxy
addNewEvent in interface SelfHealingProxy
public void onEvent(java.util.List<RemoteException> events,
RemoteException lastInserted)
SelfHealingProxy
onEvent in interface SelfHealingProxypublic TestSession getNewSession(java.util.Map<java.lang.String,java.lang.Object> requestedCapability)
getNewSession in class RemoteProxyrequestedCapability - .
public boolean isDown()
public void beforeSession(TestSession session)
For instance if a node registers: {"browserName":"firefox","version":"7.0","firefox_binary":"/home/ff7"} and later on a client requests {"browserName":"firefox","version":"7.0"} , the hub will automatically append the correct binary path to the desiredCapability before it's forwarded to the server. That way the version / install location mapping is done only once at the node level.
beforeSession in interface TestSessionListenerif the setup applies to all the tests.public void afterSession(TestSession session)
TestSessionListener
afterSession in interface TestSessionListenerpublic void teardown()
teardown in class RemoteProxy
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||