public interface Server extends DispatchableEntity<ServerEvent.Type,ServerEvent>
A Server instance represents a running ESP cluster. This can be used to query for server details and control
project deployments, starts and stops.
A Server is retrieved for the global SDK object using either SDK.getServer(Uri, Credentials) or
SDK.getServer(Uri, Credentials, ServerOptions) calls.
| Modifier and Type | Interface and Description |
|---|---|
static class |
Server.AffinityCharge |
static class |
Server.AffinityStrength |
static class |
Server.AffinityType |
static interface |
Server.Application
Application entities known to the server framework
|
static interface |
Server.Controller
Controllers in the server
|
static interface |
Server.Manager
Corresponds to an instance of Manager process running in the server framework
|
static class |
Server.Status |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes this object for further commands and queries.
|
void |
connect()
This must be the first call made to a newly retrieved server.
|
void |
disconnect()
Disconnects the server object for the current manager.
|
java.net.URL |
getConnectedURL()
The manager URL, currently connected to
|
Uri |
getConnectionUri() |
Server.Controller[] |
getControllers()
Currently known controllers.
|
Server.Manager[] |
getManagers()
Currently known manager processes.
|
ServerOptions |
getOptions()
Returns the options this server object was created with
|
Project |
getProject(java.lang.String workspace,
java.lang.String projectName)
Is equivalent to the call
#getProject(String, ProjectOptions) with default project options. |
Project |
getProject(java.lang.String workspace,
java.lang.String projectName,
ProjectOptions options)
Retrieves the Project object corresponding to the projectName.
|
Server.Application[] |
getRegisteredApplications()
Currently known applications.
|
ServerController |
getServerController() |
java.lang.String[] |
getWorkspaces()
Currently known workspaces.
|
boolean |
isClosed() |
boolean |
isVirtual()
Check if this server object corresponds to a virtual server, created in association with a standalone
project
|
deregisterSelection, dispatch, removeCallback, selectWith, setCallback, updateUri getConnectionUri()
boolean isVirtual()
void connect()
throws java.io.IOException,
javax.security.auth.login.LoginException
ServerEvent.Type.CONNECTED event, otherwise they will receive an
ServerEvent.Type.ERROR.java.io.IOException - if the connection cannot be establishedjavax.security.auth.login.LoginExceptionvoid disconnect()
throws java.io.IOException
java.io.IOExceptionvoid close()
throws java.io.IOException
java.io.IOExceptionboolean isClosed()
Project getProject(java.lang.String workspace, java.lang.String projectName) throws EntityNotFoundException, java.io.IOException, ServerErrorException
#getProject(String, ProjectOptions) with default project options.workspace - projectName - ServerErrorExceptionEntityNotFoundExceptionjava.io.IOExceptionProject getProject(java.lang.String workspace, java.lang.String projectName, ProjectOptions options) throws EntityNotFoundException, java.io.IOException, ServerErrorException
In CALLBACK or SELECT mode will return the cached object if it has been accessed before otherwise creates a
new Project object and returns it. Must be called after the a
ServerEvent.Type.APPLICATION_LIST_CHANGE event has been received.
workspace - projectName - options - EntityNotFoundExceptionjava.io.IOExceptionServerErrorExceptionServerOptions getOptions()
java.net.URL getConnectedURL()
ServerController getServerController()
Server.Manager[] getManagers() throws java.io.IOException, ServerErrorException
java.io.IOExceptionServerErrorExceptionServer.Controller[] getControllers() throws java.io.IOException, ServerErrorException
java.io.IOExceptionServerErrorExceptionjava.lang.String[] getWorkspaces()
throws java.io.IOException,
ServerErrorException
java.io.IOExceptionServerErrorExceptionServer.Application[] getRegisteredApplications() throws java.io.IOException, ServerErrorException
java.io.IOExceptionServerErrorException