public class WebAllocatedResources
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private int |
debugAgentPort
The web client java debugger port for development/testing use case
|
private java.lang.String |
forwardedHost
The forwarded host
|
private java.lang.String |
forwardedProto
The http/https protocol used by the forwarded host
|
private java.lang.String |
host
The direct host assigned to launch the spawned web client
|
private java.util.concurrent.BlockingQueue<WebAllocatedResources> |
hostResources
The associated web resource queue
|
private int |
jmxAgentPort
The web client jmx agent port for development/testing use case
|
private java.lang.String |
osUser
The user running this web client
|
private int |
port
The web client port
|
private java.util.concurrent.locks.ReentrantReadWriteLock |
readWriteLock
Read and write lock object
|
private java.lang.String |
uuid
The web client uuid
|
private java.lang.String |
webRoot
The web root prefix for all resources of the web client
|
| Constructor and Description |
|---|
WebAllocatedResources(java.lang.String host,
int port,
int debugAgentPort,
int jmxAgentPort,
java.lang.String webRoot,
java.lang.String forwardedHost,
java.lang.String forwardedProto,
java.lang.String osUser,
java.lang.String uuid,
java.util.concurrent.BlockingQueue<WebAllocatedResources> hostResources)
Creates a WebClientConfig object.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getDebugAgentPort()
Gets the java debugger port.
|
java.lang.String |
getForwardedHost()
Gets the forwarded host.
|
java.lang.String |
getForwardedProto()
Gets the forwarded host protocol.
|
java.lang.String |
getHost()
The host on which this web client is running
|
java.util.concurrent.BlockingQueue<WebAllocatedResources> |
getHostResources()
Gets a reference to its resource queue.
|
int |
getJmxAgentPort()
Gets the jmx agent port.
|
java.lang.String |
getOsUser()
Get the user running this web client.
|
int |
getPort()
Gets the web client port number.
|
java.lang.String |
getUuid()
Returns a web client unique identifier.
|
java.lang.String |
getWebRoot()
Gets the web client root.
|
void |
release()
Added allocated resources back to its queue.
|
void |
setNewClient(java.lang.String uuid,
java.lang.String webRoot,
java.lang.String osUser,
java.lang.String forwardedProto,
java.lang.String forwardedHost)
Set new client configuration for this preallocated ports configuration.
|
java.lang.String |
toString()
Get a string presentation of this object
|
private final java.util.concurrent.locks.ReentrantReadWriteLock readWriteLock
private final java.lang.String host
private final int port
private final int debugAgentPort
private final int jmxAgentPort
private final java.util.concurrent.BlockingQueue<WebAllocatedResources> hostResources
private java.lang.String webRoot
private java.lang.String forwardedHost
private java.lang.String forwardedProto
private java.lang.String osUser
private java.lang.String uuid
public WebAllocatedResources(java.lang.String host,
int port,
int debugAgentPort,
int jmxAgentPort,
java.lang.String webRoot,
java.lang.String forwardedHost,
java.lang.String forwardedProto,
java.lang.String osUser,
java.lang.String uuid,
java.util.concurrent.BlockingQueue<WebAllocatedResources> hostResources)
host - The web client host name or ip addressport - The web client portdebugAgentPort - The web client java debugger portjmxAgentPort - The web client jmx agent portwebRoot - The web rootforwardedHost - The forwarded hostforwardedProto - The forwarded protocolosUser - The OS user name/iduuid - The web client uuidhostResources - The host resources queuepublic java.lang.String getHost()
public int getPort()
public int getDebugAgentPort()
public int getJmxAgentPort()
public java.util.concurrent.BlockingQueue<WebAllocatedResources> getHostResources()
public java.lang.String getUuid()
public java.lang.String getWebRoot()
public java.lang.String getForwardedHost()
public java.lang.String getForwardedProto()
public java.lang.String getOsUser()
public void release()
throws java.lang.InterruptedException
java.lang.InterruptedException - If interrupted while waitingpublic java.lang.String toString()
toString in class java.lang.Objectpublic void setNewClient(java.lang.String uuid,
java.lang.String webRoot,
java.lang.String osUser,
java.lang.String forwardedProto,
java.lang.String forwardedHost)
uuid - The uuid to setwebRoot - The webRoot to setosUser - The OS user to setforwardedProto - The forwardedProto to setforwardedHost - The forwardedHost to set