|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.zeroturnaround.liverebel.api.impl.CommandCenterImpl
public class CommandCenterImpl
CommandCenter,
CommandCenterFactory| Constructor Summary | |
|---|---|
CommandCenterImpl(String url,
String username,
String password,
boolean verbose)
|
|
| Method Summary | |
|---|---|
boolean |
addGroupChild(String groupName,
String childGroupName)
|
boolean |
addServersToGroup(String groupName,
Collection<String> serverIds)
|
boolean |
cancelUpdate(Long updateId)
Cancels manual update by id. |
boolean |
checkPrimaryAlive()
|
DiffResult |
compare(String applicationId,
String fromVersionId,
String toVersionId,
boolean full)
Compares two versions of the given application. |
int |
countSeats()
|
boolean |
createGroup(String name,
String description,
Collection<String> serverIds)
|
int |
deleteAllLicenses()
|
boolean |
deleteGroup(String name)
|
void |
deploy(String applicationId,
String versionId,
String ctxPath,
Collection<String> servers)
Deploy application to specified servers. |
void |
deploy(String applicationId,
String versionId,
String ctxPath,
Collection<String> servers,
Collection<String> groups)
Deploy application to specified servers. |
ApplicationInfo |
enableNinjaMode(String serverId,
String appId)
Enables inplace edit mode (ninja) for given application on a given server |
List<ServerInfo> |
expandGroup(String groupName)
|
ApplicationInfo |
finishNinjaUpdate(String serverId,
String appId,
String verId)
Finishes inplace edit (ninja) update on given server for given application. |
ApplicationInfo |
getApplication(String applicationId)
Returns current info about an application. |
Map<String,ApplicationInfo> |
getApplications()
Lists all applications. |
CommandCenterUpdate |
getCommandCenterUpdate()
|
List<ServerGroup> |
getGroups(String name)
|
Date |
getLastFailoverSyncTime()
Returns date of last time when this servers synced with failover server. |
PausedUpdate |
getPausedUpdate(Long id)
Returns a paused update by its Id. |
List<Long> |
getRunningPausedUpdateIds()
|
ServerInfo |
getServer(String serverId)
Returns current info about a server. |
Map<String,ServerInfo> |
getServers()
Lists all servers. |
boolean |
getVerbose()
|
boolean |
isAlive()
|
boolean |
registerAsFailover(String primaryHost,
int primaryPort,
String token)
Returns true is registration was OK. |
void |
remove(String appId)
Removes app from command center. |
boolean |
removeGroupChild(String groupName,
String childGroupName)
|
void |
removeServer(String serverId)
Removes a server. |
boolean |
removeServersFromGroup(String groupName,
Collection<String> serverIds)
|
void |
removeVersion(String appId,
String versionId)
Removes application version from command center. |
boolean |
resumeUpdate(Long updateId)
Resumes manual update by id. |
void |
syncWithFailover()
If this server has failover slave - this will schedule synchronizing in 3s. |
void |
undeploy(String applicationId,
Collection<String> servers)
Undeploy application from specified servers. |
void |
undeploy(String applicationId,
Collection<String> servers,
Collection<String> groups)
Undeploy application from specified servers. |
ConfigurableUpdate |
update(String applicationId,
String versionId)
Start updating an application to a given version. |
AgentUpdate |
updateAgent()
|
UploadInfo |
upload(File file)
Uploads new version of an application. |
UploadInfo |
upload(String applicationId,
String fromVersion,
File diff)
Uploads new version of an application. |
boolean |
uploadLicense(File license)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CommandCenterImpl(String url,
String username,
String password,
boolean verbose)
| Method Detail |
|---|
public boolean isAlive()
isAlive in interface CommandCentertrue if the Command Center is alive.public Map<String,ServerInfo> getServers()
CommandCenter
getServers in interface CommandCenterpublic ServerInfo getServer(String serverId)
CommandCenter
getServer in interface CommandCenterserverId - server Id.
public void removeServer(String serverId)
CommandCenter
removeServer in interface CommandCenterserverId - server Id.public Map<String,ApplicationInfo> getApplications()
CommandCenter
getApplications in interface CommandCenterpublic ApplicationInfo getApplication(String applicationId)
CommandCenter
getApplication in interface CommandCenterapplicationId - application Id.
public UploadInfo upload(File file)
CommandCenter
upload in interface CommandCenterfile - archive file.
public DiffResult compare(String applicationId,
String fromVersionId,
String toVersionId,
boolean full)
CommandCenter
compare in interface CommandCenterapplicationId - application Id.fromVersionId - current version Id.toVersionId - new version Id.full - include all differences (otherwise only warnings and errors are included).
public ConfigurableUpdate update(String applicationId,
String versionId)
CommandCenter
update in interface CommandCenterapplicationId - application Id.versionId - version Id.public PausedUpdate getPausedUpdate(Long id)
CommandCenter
getPausedUpdate in interface CommandCenterid - update Id.
null if no such update found.PreparedPausableUpdate.executeWithPause()
public boolean registerAsFailover(String primaryHost,
int primaryPort,
String token)
CommandCenter
registerAsFailover in interface CommandCenterprimaryHost - - primary server hostprimaryPort - - primary server porttoken - - primary server user auth-token that will be used for initial authentication
public void syncWithFailover()
CommandCenter
syncWithFailover in interface CommandCenterpublic boolean checkPrimaryAlive()
checkPrimaryAlive in interface CommandCenterpublic boolean getVerbose()
getVerbose in interface CommandCenter
public void deploy(String applicationId,
String versionId,
String ctxPath,
Collection<String> servers)
CommandCenter
deploy in interface CommandCenterapplicationId - - application idctxPath - - context path for serversservers - - server jvmid-s
public void deploy(String applicationId,
String versionId,
String ctxPath,
Collection<String> servers,
Collection<String> groups)
CommandCenter
deploy in interface CommandCenterapplicationId - - application idctxPath - - context path for serversservers - - server jvmid-s
public void undeploy(String applicationId,
Collection<String> servers)
CommandCenter
undeploy in interface CommandCenterapplicationId - - application idservers - - server jvmid-s
public void undeploy(String applicationId,
Collection<String> servers,
Collection<String> groups)
CommandCenter
undeploy in interface CommandCenterapplicationId - - application idservers - - server jvmid-spublic void remove(String appId)
CommandCenter
remove in interface CommandCenter
public void removeVersion(String appId,
String versionId)
CommandCenter
removeVersion in interface CommandCenterpublic Date getLastFailoverSyncTime()
CommandCenter
getLastFailoverSyncTime in interface CommandCenterpublic boolean resumeUpdate(Long updateId)
CommandCenter
resumeUpdate in interface CommandCenterpublic boolean cancelUpdate(Long updateId)
CommandCenter
cancelUpdate in interface CommandCenterpublic List<Long> getRunningPausedUpdateIds()
getRunningPausedUpdateIds in interface CommandCenter
public UploadInfo upload(String applicationId,
String fromVersion,
File diff)
throws DuplicationException
CommandCenter
upload in interface CommandCenterapplicationId - - application identificatorfromVersion - - version on which this diff is based
DuplicationException - if the given version already exists on the server.
public ApplicationInfo enableNinjaMode(String serverId,
String appId)
CommandCenter
enableNinjaMode in interface CommandCenter
public ApplicationInfo finishNinjaUpdate(String serverId,
String appId,
String verId)
CommandCenter
finishNinjaUpdate in interface CommandCenterpublic int countSeats()
countSeats in interface CommandCenterpublic boolean uploadLicense(File license)
uploadLicense in interface CommandCenterpublic int deleteAllLicenses()
deleteAllLicenses in interface CommandCenter
public boolean createGroup(String name,
String description,
Collection<String> serverIds)
createGroup in interface CommandCenter
public boolean addServersToGroup(String groupName,
Collection<String> serverIds)
addServersToGroup in interface CommandCenter
public boolean removeServersFromGroup(String groupName,
Collection<String> serverIds)
removeServersFromGroup in interface CommandCenterpublic List<ServerGroup> getGroups(String name)
getGroups in interface CommandCenterpublic List<ServerInfo> expandGroup(String groupName)
expandGroup in interface CommandCenterpublic boolean deleteGroup(String name)
deleteGroup in interface CommandCenter
public boolean addGroupChild(String groupName,
String childGroupName)
addGroupChild in interface CommandCenter
public boolean removeGroupChild(String groupName,
String childGroupName)
removeGroupChild in interface CommandCenterpublic CommandCenterUpdate getCommandCenterUpdate()
getCommandCenterUpdate in interface CommandCenterpublic AgentUpdate updateAgent()
updateAgent in interface CommandCenter
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||