public interface CloudControllerClient
| Modifier and Type | Method and Description |
|---|---|
void |
addDomain(String domainName)
Add a private domain in the current organization.
|
void |
addRoute(String host,
String domainName,
String path)
Register a new route to the a domain.
|
void |
associateAuditorWithSpace(String spaceName)
Associate current user to the space auditors role
|
void |
associateAuditorWithSpace(String organizationName,
String spaceName)
Associate current user to the space auditors role
|
void |
associateAuditorWithSpace(String organizationName,
String spaceName,
String userGuid)
Associate a user to the space auditors role
|
void |
associateDeveloperWithSpace(String spaceName)
Associate current user to the space developer role
|
void |
associateDeveloperWithSpace(String organizationName,
String spaceName)
Associate current user to the space developer role
|
void |
associateDeveloperWithSpace(String organizationName,
String spaceName,
String userGuid)
Associate a user to the space developer role
|
void |
associateManagerWithSpace(String spaceName)
Associate current user to the space managers role
|
void |
associateManagerWithSpace(String organizationName,
String spaceName)
Associate current user to the space managers role
|
void |
associateManagerWithSpace(String organizationName,
String spaceName,
String userGuid)
Associate a user to the space managers role
|
UploadToken |
asyncUploadApplication(String applicationName,
File file) |
UploadToken |
asyncUploadApplication(String applicationName,
File file,
UploadStatusCallback callback) |
void |
bindDropletToApp(UUID dropletGuid,
UUID applicationGuid) |
void |
bindRunningSecurityGroup(String securityGroupName)
Bind a security group to the list of security groups to be used for running applications.
|
void |
bindSecurityGroup(String organizationName,
String spaceName,
String securityGroupName)
Bind a security group to a space.
|
void |
bindService(String applicationName,
String serviceName)
Associate (provision) a service with an application.
|
void |
bindService(String applicationName,
String serviceName,
Map<String,Object> parameters,
ApplicationServicesUpdateCallback updateServicesCallback)
Associate (provision) a service with an application.
|
void |
bindStagingSecurityGroup(String securityGroupName)
Bind a security group to the list of security groups to be used for staging applications.
|
CloudTask |
cancelTask(UUID taskGuid)
Cancel the given task.
|
void |
createApplication(String applicationName,
Staging staging,
Integer disk,
Integer memory,
List<String> uris,
List<String> serviceNames,
DockerInfo dockerInfo)
Create application.
|
void |
createApplication(String applicationName,
Staging staging,
Integer memory,
List<String> uris,
List<String> serviceNames)
Create application.
|
CloudBuild |
createBuild(UUID packageGuid) |
void |
createQuota(CloudQuota quota)
Create quota
|
void |
createSecurityGroup(CloudSecurityGroup securityGroup)
Create a new CloudSecurityGroup.
|
void |
createSecurityGroup(String name,
InputStream jsonRulesFile)
Create a new CloudSecurityGroup using a JSON rules file.
|
void |
createService(CloudService service)
Create a service.
|
void |
createServiceBroker(CloudServiceBroker serviceBroker)
Create a service broker.
|
CloudServiceKey |
createServiceKey(String serviceName,
String serviceKeyName,
Map<String,Object> parameters)
Create a service key.
|
void |
createSpace(String spaceName)
Create a space with the specified name
|
void |
createUserProvidedService(CloudService service,
Map<String,Object> credentials)
Create a user-provided service.
|
void |
createUserProvidedService(CloudService service,
Map<String,Object> credentials,
String syslogDrainUrl)
Create a user-provided service for logging.
|
void |
deleteAllApplications()
Delete all applications.
|
void |
deleteAllServices()
Delete all services.
|
void |
deleteApplication(String applicationName)
Delete application.
|
void |
deleteDomain(String domainName)
Delete a private domain in the current organization.
|
List<CloudRoute> |
deleteOrphanedRoutes()
Delete routes that do not have any application which is assigned to them.
|
void |
deleteQuota(String quotaName)
Delete quota by name
|
void |
deleteRoute(String host,
String domainName,
String path)
Delete a registered route from the space of the current session.
|
void |
deleteSecurityGroup(String securityGroupName)
Deletes the security group with the given name.
|
void |
deleteService(String service)
Delete cloud service.
|
void |
deleteServiceBroker(String name)
Delete a service broker.
|
void |
deleteServiceKey(String service,
String serviceKey)
Delete a service key.
|
void |
deleteSpace(String spaceName)
Delete a space with the specified name
|
CloudApplication |
getApplication(String applicationName)
Get cloud application with the specified name.
|
CloudApplication |
getApplication(String applicationName,
boolean required)
Get cloud application with the specified name.
|
CloudApplication |
getApplication(UUID guid)
Get cloud application with the specified GUID.
|
Map<String,String> |
getApplicationEnvironment(String applicationName)
Get application environment variables for the app with the specified name.
|
Map<String,String> |
getApplicationEnvironment(UUID applicationGuid)
Get application environment variables for the app with the specified GUID.
|
List<CloudEvent> |
getApplicationEvents(String applicationName)
Get application events.
|
InstancesInfo |
getApplicationInstances(CloudApplication app)
Get application instances info for application.
|
InstancesInfo |
getApplicationInstances(String applicationName)
Get application instances info for application.
|
List<CloudApplication> |
getApplications()
Get all cloud applications.
|
List<CloudApplication> |
getApplicationsByMetadataLabelSelector(String labelSelector) |
CloudBuild |
getBuild(UUID buildGuid) |
List<CloudBuild> |
getBuildsForApplication(UUID applicationGuid) |
List<CloudBuild> |
getBuildsForPackage(UUID packageGuid) |
URL |
getCloudControllerUrl()
Get the URL used for the cloud controller.
|
CloudInfo |
getCloudInfo()
Get CloudInfo for the current cloud.
|
Map<String,String> |
getCrashLogs(String applicationName)
Deprecated.
Use
#streamLogs(String, ApplicationLogListener) or getRecentLogs(String) |
CloudDomain |
getDefaultDomain()
Gets the default domain for the current org, which is the first shared domain.
|
List<CloudDomain> |
getDomains()
Get list of all domain shared and private domains.
|
List<CloudDomain> |
getDomainsForOrganization()
Get list of all domain registered for the current organization.
|
List<CloudEvent> |
getEvents()
Get system events.
|
String |
getFile(String applicationName,
int instanceIndex,
String filePath)
Get file from the deployed application.
|
String |
getFile(String applicationName,
int instanceIndex,
String filePath,
int startPosition)
Get a the content, starting at a specific position, of a file from the deployed application.
|
String |
getFile(String applicationName,
int instanceIndex,
String filePath,
int startPosition,
int endPosition)
Get a range of content of a file from the deployed application.
|
String |
getFileTail(String applicationName,
int instanceIndex,
String filePath,
int length)
Get a the last bytes, with length as specified, of content of a file from the deployed application.
|
Map<String,String> |
getLogs(String applicationName)
Deprecated.
Use
#streamLogs(String, ApplicationLogListener) or getRecentLogs(String) |
CloudOrganization |
getOrganization(String organizationName)
Get the organization with the specified name.
|
CloudOrganization |
getOrganization(String organizationName,
boolean required)
Get the organization with the specified name.
|
List<CloudOrganization> |
getOrganizations()
Get list of CloudOrganizations for the current cloud.
|
Map<String,CloudUser> |
getOrganizationUsers(String organizationName)
Get all users in the specified organization
|
List<CloudDomain> |
getPrivateDomains()
Get list of all private domains.
|
CloudQuota |
getQuota(String quotaName)
Get quota by name
|
CloudQuota |
getQuota(String quotaName,
boolean required)
Get quota by name
|
List<CloudQuota> |
getQuotas()
Get quota definitions
|
List<ApplicationLog> |
getRecentLogs(String applicationName)
Stream recent log entries.
|
List<ApplicationLog> |
getRecentLogs(UUID applicationGuid)
Get recent log entries.
|
List<CloudRoute> |
getRoutes(String domainName)
Get the info for all routes for a domain.
|
List<CloudSecurityGroup> |
getRunningSecurityGroups()
List security groups in the set of security groups for running applications.
|
CloudSecurityGroup |
getSecurityGroup(String securityGroupName)
Get a specific security group by name.
|
CloudSecurityGroup |
getSecurityGroup(String securityGroupName,
boolean required)
Get a specific security group by name.
|
List<CloudSecurityGroup> |
getSecurityGroups()
Get a List of all application security groups.
|
CloudService |
getService(String service)
Get cloud service.
|
CloudService |
getService(String service,
boolean required)
Get cloud service.
|
CloudServiceBroker |
getServiceBroker(String name)
Get a service broker.
|
CloudServiceBroker |
getServiceBroker(String name,
boolean required)
Get a service broker.
|
List<CloudServiceBroker> |
getServiceBrokers()
Get all service brokers.
|
CloudServiceInstance |
getServiceInstance(String service)
Get a service instance.
|
CloudServiceInstance |
getServiceInstance(String service,
boolean required)
Get a service instance.
|
List<CloudServiceKey> |
getServiceKeys(String serviceName)
Get service keys for a service.
|
List<CloudServiceOffering> |
getServiceOfferings()
Get all service offerings.
|
Map<String,Object> |
getServiceParameters(UUID guid)
Get all service parameters.
|
List<CloudService> |
getServices()
Get list of cloud services.
|
List<CloudService> |
getServicesByMetadataLabelSelector(String labelSelector) |
List<CloudDomain> |
getSharedDomains()
Get list of all shared domains.
|
CloudSpace |
getSpace(String spaceName)
Get space name with the specified name.
|
CloudSpace |
getSpace(String spaceName,
boolean required)
Get space name with the specified name.
|
CloudSpace |
getSpace(String organizationName,
String spaceName)
Get space name with the specified name.
|
CloudSpace |
getSpace(String organizationName,
String spaceName,
boolean required)
Get space name with the specified name.
|
CloudSpace |
getSpace(UUID spaceGuid)
Get space name with the specified GUID.
|
List<UUID> |
getSpaceAuditors() |
List<UUID> |
getSpaceAuditors(String spaceName)
Get list of space auditor UUID for the space.
|
List<UUID> |
getSpaceAuditors(String organizationName,
String spaceName)
Get list of space auditor UUID for the space.
|
List<UUID> |
getSpaceAuditors(UUID spaceGuid) |
List<UUID> |
getSpaceDevelopers() |
List<UUID> |
getSpaceDevelopers(String spaceName)
Get list of space developer UUID for the space.
|
List<UUID> |
getSpaceDevelopers(String organizationName,
String spaceName)
Get list of space developer UUID for the space.
|
List<UUID> |
getSpaceDevelopers(UUID spaceGuid) |
List<UUID> |
getSpaceManagers() |
List<UUID> |
getSpaceManagers(String spaceName)
Get list of space manager UUID for the space.
|
List<UUID> |
getSpaceManagers(String organizationName,
String spaceName)
Get list of space manager UUID for the space.
|
List<UUID> |
getSpaceManagers(UUID spaceGuid) |
List<CloudSpace> |
getSpaces()
Get list of CloudSpaces for the current cloud.
|
List<CloudSpace> |
getSpaces(String organizationName)
Get list of CloudSpaces for organization.
|
List<CloudSpace> |
getSpacesBoundToSecurityGroup(String securityGroupName)
Gets all the spaces that are bound to the given security group.
|
CloudStack |
getStack(String name)
Get a stack by name.
|
CloudStack |
getStack(String name,
boolean required)
Get a stack by name.
|
List<CloudStack> |
getStacks()
Get the list of stacks available for staging applications.
|
List<CloudSecurityGroup> |
getStagingSecurityGroups()
Lists security groups in the staging set for applications.
|
CloudTask |
getTask(UUID taskGuid) |
List<CloudTask> |
getTasks(String applicationName)
Get the list of one-off tasks currently known for the given application.
|
Upload |
getUploadStatus(UUID packageGuid) |
org.springframework.security.oauth2.common.OAuth2AccessToken |
login()
Login using the credentials already set for the client.
|
void |
logout()
Logout closing the current session.
|
void |
register(String email,
String password)
Register new user account with the provided credentials.
|
void |
registerRestLogListener(RestLogCallback callBack)
Register a new RestLogCallback
|
void |
removeDomain(String domainName)
Deprecated.
alias for
deleteDomain(java.lang.String) |
void |
rename(String applicationName,
String newName)
Rename an application.
|
StartingInfo |
restartApplication(String applicationName)
Restart application.
|
CloudTask |
runTask(String applicationName,
CloudTask task)
Run a one-off task on an application.
|
void |
setQuotaToOrganization(String organizationName,
String quotaName)
Set quota to organization
|
void |
setResponseErrorHandler(org.springframework.web.client.ResponseErrorHandler errorHandler)
Override the default REST response error handler with a custom error handler.
|
StartingInfo |
startApplication(String applicationName)
Start application.
|
void |
stopApplication(String applicationName)
Stop application.
|
void |
unbindRunningSecurityGroup(String securityGroupName)
Unbind a security group from the set of security groups for running applications.
|
void |
unbindSecurityGroup(String organizationName,
String spaceName,
String securityGroupName)
Unbind a security group from a space.
|
void |
unbindService(String applicationName,
String serviceName)
Un-associate (unprovision) a service from an application.
|
void |
unbindService(String applicationName,
String serviceName,
ApplicationServicesUpdateCallback applicationServicesUpdateCallback)
Un-associate (unprovision) a service from an application.
|
void |
unbindStagingSecurityGroup(String securityGroupName)
Unbind a security group from the set of security groups for staging applications.
|
void |
unregister()
Unregister and log out the currently logged in user
|
void |
unRegisterRestLogListener(RestLogCallback callBack)
Un-register a RestLogCallback
|
void |
updateApplicationDiskQuota(String applicationName,
int disk)
Update application disk quota.
|
void |
updateApplicationEnv(String applicationName,
Map<String,String> env)
Update application env using a map where the key specifies the name of the environment variable and the value the value of the
environment variable..
|
void |
updateApplicationInstances(String applicationName,
int instances)
Update application instances.
|
void |
updateApplicationMemory(String applicationName,
int memory)
Update application memory.
|
void |
updateApplicationMetadata(UUID guid,
org.cloudfoundry.client.v3.Metadata metadata) |
void |
updateApplicationStaging(String applicationName,
Staging staging)
Update application staging information.
|
void |
updateApplicationUris(String applicationName,
List<String> uris)
Update application URIs.
|
void |
updatePassword(CloudCredentials credentials,
String newPassword)
Update the password for the logged in user using the username/old_password provided in the credentials.
|
void |
updatePassword(String newPassword)
Update the password for the logged in user.
|
void |
updateQuota(CloudQuota quota,
String name)
Update Quota definition
|
void |
updateSecurityGroup(CloudSecurityGroup securityGroup)
Update an existing security group.
|
void |
updateSecurityGroup(String name,
InputStream jsonRulesFile)
Updates a existing CloudSecurityGroup using a JSON rules file.
|
void |
updateServiceBroker(CloudServiceBroker serviceBroker)
Update a service broker (unchanged forces catalog refresh).
|
void |
updateServiceMetadata(UUID guid,
org.cloudfoundry.client.v3.Metadata metadata) |
void |
updateServicePlanVisibilityForBroker(String name,
boolean visibility)
Service plans are private by default when a service broker's catalog is fetched/updated.
|
void |
uploadApplication(String applicationName,
File file)
Upload an application to Cloud Foundry.
|
void |
uploadApplication(String applicationName,
File file,
UploadStatusCallback callback)
Upload an application to Cloud Foundry.
|
void |
uploadApplication(String applicationName,
InputStream inputStream)
Upload an application to Cloud Foundry.
|
void |
uploadApplication(String applicationName,
InputStream inputStream,
UploadStatusCallback callback)
Upload an application to Cloud Foundry.
|
void |
uploadApplication(String applicationName,
String file)
Upload an application to Cloud Foundry.
|
void addDomain(String domainName)
domainName - the domain to addvoid addRoute(String host, String domainName, String path)
host - the host of the route to registerdomainName - the domain of the route to registervoid associateAuditorWithSpace(String spaceName)
spaceName - name of the spacevoid associateAuditorWithSpace(String organizationName, String spaceName)
organizationName - name of the organization containing the spacespaceName - name of the spacevoid associateAuditorWithSpace(String organizationName, String spaceName, String userGuid)
organizationName - name of the organization containing the spacespaceName - name of the spaceuserGuid - guid of the user. If null, use current user. To retrieve user guid, use getOrganizationUsers and search for usernamevoid associateDeveloperWithSpace(String spaceName)
spaceName - name of the spacevoid associateDeveloperWithSpace(String organizationName, String spaceName)
organizationName - name of the organization containing the spacespaceName - name of the spacevoid associateDeveloperWithSpace(String organizationName, String spaceName, String userGuid)
organizationName - name of the organization containing the spacespaceName - name of the spaceuserGuid - guid of the user. If null, use current user. To retrieve user guid, use getOrganizationUsers and search for usernamevoid associateManagerWithSpace(String spaceName)
spaceName - name of the spacevoid associateManagerWithSpace(String organizationName, String spaceName)
organizationName - name of the organization containing the spacespaceName - name of the spacevoid associateManagerWithSpace(String organizationName, String spaceName, String userGuid)
organizationName - name of the organization containing the spacespaceName - name of the spaceuserGuid - guid of the user. If null, use current user. To retrieve user guid, use getOrganizationUsers and search for usernamevoid bindRunningSecurityGroup(String securityGroupName)
void bindSecurityGroup(String organizationName, String spaceName, String securityGroupName)
organizationName - The name of the organization that the space is in.spaceName - The name of the spacesecurityGroupName - The name of the security group to bind to the spaceCloudOperationException - if the org, space, or security group do not existvoid bindService(String applicationName, String serviceName)
applicationName - the application nameserviceName - the service namevoid bindService(String applicationName, String serviceName, Map<String,Object> parameters, ApplicationServicesUpdateCallback updateServicesCallback)
applicationName - the application nameserviceName - the service nameparameters - the binding parametersapplicationServicesUpdateCallback - callback used for error handlingvoid bindStagingSecurityGroup(String securityGroupName)
void createApplication(String applicationName, Staging staging, Integer memory, List<String> uris, List<String> serviceNames)
applicationName - application namestaging - staging infomemory - memory to use in MBuris - list of URIs for the appserviceNames - list of service names to bind to appvoid createApplication(String applicationName, Staging staging, Integer disk, Integer memory, List<String> uris, List<String> serviceNames, DockerInfo dockerInfo)
applicationName - application namestaging - staging infodisk - disk quota to use in MBmemory - memory to use in MBuris - list of URIs for the appserviceNames - list of service names to bind to appdockerInfo - docker params(image, username, password)void createQuota(CloudQuota quota)
quota - void createSecurityGroup(CloudSecurityGroup securityGroup)
securityGroup - void createSecurityGroup(String name, InputStream jsonRulesFile)
cf create-security-group
SECURITY-GROUP PATH-TO-RULES-FILE when using the cf command line. See the Application Security Group documentation for more
details.
Example JSON-formatted rules file:
[
{
"protocol":"tcp",
"destination":"10.0.11.0/24",
"ports":"1-65535"
},
{
"protocol":"udp",
"destination":"10.0.11.0/24",
"ports":"1-65535"
}
]
This method requires the logged in user to have admin permissions in the cloud controller.name - the name for the security groupjsonRulesFile - An input stream that has a single array with JSON objects inside describing the ruleshttp://docs.cloudfoundry.org/adminguide/app-sec-groups.htmlvoid createService(CloudService service)
service - cloud service infovoid createServiceBroker(CloudServiceBroker serviceBroker)
serviceBroker - cloud service broker infoCloudServiceKey createServiceKey(String serviceName, String serviceKeyName, Map<String,Object> parameters)
service - name of serviceserviceKey - name of service-keyparameters - parameters of service-keyvoid createSpace(String spaceName)
spaceName - void createUserProvidedService(CloudService service, Map<String,Object> credentials)
service - cloud service infocredentials - the user-provided service credentialsvoid createUserProvidedService(CloudService service, Map<String,Object> credentials, String syslogDrainUrl)
service - cloud service infocredentials - the user-provided service credentialssyslogDrainUrl - for a logging servicevoid deleteAllApplications()
void deleteAllServices()
void deleteApplication(String applicationName)
applicationName - name of applicationvoid deleteDomain(String domainName)
domainName - the domain to deleteList<CloudRoute> deleteOrphanedRoutes()
void deleteQuota(String quotaName)
quotaName - void deleteRoute(String host, String domainName, String path)
host - the host of the route to deletedomainName - the domain of the route to deletevoid deleteSecurityGroup(String securityGroupName)
securityGroupName - CloudOperationException - if a security group does not exist with the given namevoid deleteService(String service)
service - name of servicevoid deleteServiceBroker(String name)
name - the service broker namevoid deleteServiceKey(String service, String serviceKey)
serviceName - name of serviceserviceKey - name of service keyvoid deleteSpace(String spaceName)
spaceName - name of the spaceCloudApplication getApplication(String applicationName)
applicationName - name of the appCloudApplication getApplication(String applicationName, boolean required)
applicationName - name of the apprequired - if true, and organization is not found, throw an exceptionCloudApplication getApplication(UUID guid)
guid - GUID of the appMap<String,String> getApplicationEnvironment(String applicationName)
applicationName - name of the appMap<String,String> getApplicationEnvironment(UUID applicationGuid)
applicationGuid - GUID of the appList<CloudEvent> getApplicationEvents(String applicationName)
applicationName - name of applicationInstancesInfo getApplicationInstances(String applicationName)
applicationName - name of application.InstancesInfo getApplicationInstances(CloudApplication app)
app - the application.List<CloudApplication> getApplications()
URL getCloudControllerUrl()
CloudInfo getCloudInfo()
@Deprecated Map<String,String> getCrashLogs(String applicationName)
#streamLogs(String, ApplicationLogListener) or getRecentLogs(String)applicationName - name of the applicationCloudDomain getDefaultDomain()
List<CloudDomain> getDomains()
List<CloudDomain> getDomainsForOrganization()
List<CloudEvent> getEvents()
String getFile(String applicationName, int instanceIndex, String filePath)
applicationName - name of the applicationinstanceIndex - instance indexfilePath - path to the fileString getFile(String applicationName, int instanceIndex, String filePath, int startPosition)
applicationName - name of the applicationinstanceIndex - instance indexfilePath - path to the filestartPosition - the starting position of the file contents (inclusive)String getFile(String applicationName, int instanceIndex, String filePath, int startPosition, int endPosition)
applicationName - name of the applicationinstanceIndex - instance indexfilePath - path to the filestartPosition - the starting position of the file contents (inclusive)endPosition - the ending position of the file contents (exclusive)String getFileTail(String applicationName, int instanceIndex, String filePath, int length)
applicationName - name of the applicationinstanceIndex - instance indexfilePath - path to the filelength - the length of the file contents to retrieve@Deprecated Map<String,String> getLogs(String applicationName)
#streamLogs(String, ApplicationLogListener) or getRecentLogs(String)applicationName - name of the applicationCloudOrganization getOrganization(String organizationName)
organizationName - name of organizationCloudOrganization getOrganization(String organizationName, boolean required)
organizationName - name of organizationrequired - if true, and organization is not found, throw an exceptionMap<String,CloudUser> getOrganizationUsers(String organizationName)
organizationName - organization nameCloudOperationException - if the organization do not existList<CloudOrganization> getOrganizations()
List<CloudDomain> getPrivateDomains()
CloudQuota getQuota(String quotaName)
quotaName - CloudQuota getQuota(String quotaName, boolean required)
quotaName - required - if true, and organization is not found, throw an exceptionList<CloudQuota> getQuotas()
List<ApplicationLog> getRecentLogs(String applicationName)
applicationName - the name of the applicationList<ApplicationLog> getRecentLogs(UUID applicationGuid)
applicationGuid - the guid of the applicationList<CloudRoute> getRoutes(String domainName)
domainName - the domain the routes belong toList<CloudSecurityGroup> getRunningSecurityGroups()
CloudSecurityGroup getSecurityGroup(String securityGroupName)
securityGroupName - The name of the security groupCloudSecurityGroup getSecurityGroup(String securityGroupName, boolean required)
securityGroupName - The name of the security grouprequired - if true, and organization is not found, throw an exceptionnull if no security groups exist with the given nameList<CloudSecurityGroup> getSecurityGroups()
CloudSecurityGroups in the systemCloudService getService(String service)
service - name of serviceCloudService getService(String service, boolean required)
service - name of servicerequired - if true, and organization is not found, throw an exceptionCloudServiceBroker getServiceBroker(String name)
name - the service broker nameCloudServiceBroker getServiceBroker(String name, boolean required)
name - the service broker namerequired - if true, and organization is not found, throw an exceptionList<CloudServiceBroker> getServiceBrokers()
CloudServiceInstance getServiceInstance(String service)
service - name of the service instanceMap<String,Object> getServiceParameters(UUID guid)
guid - The service instance guidCloudServiceInstance getServiceInstance(String service, boolean required)
service - name of the service instancerequired - if true, and organization is not found, throw an exceptionList<CloudServiceKey> getServiceKeys(String serviceName)
service - name containing service keysList<CloudServiceOffering> getServiceOfferings()
List<CloudService> getServices()
List<CloudDomain> getSharedDomains()
CloudSpace getSpace(UUID spaceGuid)
CloudSpace getSpace(String organizationName, String spaceName)
CloudSpace getSpace(String organizationName, String spaceName, boolean required)
CloudSpace getSpace(String spaceName)
CloudSpace getSpace(String spaceName, boolean required)
List<UUID> getSpaceAuditors(String spaceName)
spaceName - name of the spaceList<UUID> getSpaceAuditors(String organizationName, String spaceName)
organizationName - name of the organization containing the spacespaceName - name of the spaceList<UUID> getSpaceDevelopers(String spaceName)
spaceName - name of the spaceList<UUID> getSpaceDevelopers(String organizationName, String spaceName)
organizationName - name of the organization containing the spacespaceName - name of the spaceList<UUID> getSpaceManagers(String spaceName)
spaceName - name of the spaceList<UUID> getSpaceManagers(String organizationName, String spaceName)
organizationName - name of the organization containing the spacespaceName - name of the spaceList<CloudSpace> getSpaces()
List<CloudSpace> getSpaces(String organizationName)
List<CloudSpace> getSpacesBoundToSecurityGroup(String securityGroupName)
CloudStack getStack(String name)
name - the name of the stack to getCloudStack getStack(String name, boolean required)
name - the name of the stack to getrequired - if true, and organization is not found, throw an exceptionList<CloudStack> getStacks()
List<CloudSecurityGroup> getStagingSecurityGroups()
org.springframework.security.oauth2.common.OAuth2AccessToken login()
void logout()
void register(String email, String password)
email - the email accountpassword - the passwordvoid registerRestLogListener(RestLogCallback callBack)
callBack - the callback to be registered@Deprecated void removeDomain(String domainName)
deleteDomain(java.lang.String)domainName - the domain to removevoid rename(String applicationName, String newName)
applicationName - the current namenewName - the new nameStartingInfo restartApplication(String applicationName)
applicationName - name of applicationvoid setQuotaToOrganization(String organizationName, String quotaName)
organizationName - quotaName - void setResponseErrorHandler(org.springframework.web.client.ResponseErrorHandler errorHandler)
errorHandler - StartingInfo startApplication(String applicationName)
applicationName - name of applicationvoid stopApplication(String applicationName)
applicationName - name of applicationvoid unRegisterRestLogListener(RestLogCallback callBack)
callBack - the callback to be un-registeredvoid unbindRunningSecurityGroup(String securityGroupName)
void unbindSecurityGroup(String organizationName, String spaceName, String securityGroupName)
organizationName - The name of the organization that the space is in.spaceName - The name of the spacesecurityGroupName - The name of the security group to bind to the spaceCloudOperationException - if the org, space, or security group do not existvoid unbindService(String applicationName, String serviceName, ApplicationServicesUpdateCallback applicationServicesUpdateCallback)
applicationName - the application nameserviceName - the service nameapplicationServicesUpdateCallback - callback used for error handlingvoid unbindService(String applicationName, String serviceName)
applicationName - the application nameserviceName - the service namevoid unbindStagingSecurityGroup(String securityGroupName)
void unregister()
void updateApplicationDiskQuota(String applicationName, int disk)
applicationName - name of applicationdisk - new disk setting in MBvoid updateApplicationEnv(String applicationName, Map<String,String> env)
applicationName - name of applicationenv - map of environment settingsvoid updateApplicationInstances(String applicationName, int instances)
applicationName - name of applicationinstances - number of instances to usevoid updateApplicationMemory(String applicationName, int memory)
applicationName - name of applicationmemory - new memory setting in MBvoid updateApplicationStaging(String applicationName, Staging staging)
applicationName - name of appplicationstaging - staging information for the appvoid updateApplicationUris(String applicationName, List<String> uris)
applicationName - name of applicationuris - list of URIs the app should usevoid updatePassword(String newPassword)
newPassword - the new passwordvoid updatePassword(CloudCredentials credentials, String newPassword)
credentials - current credentialsnewPassword - the new passwordvoid updateQuota(CloudQuota quota, String name)
quota - name - void updateSecurityGroup(CloudSecurityGroup securityGroup)
securityGroup - CloudOperationException - if a security group does not exist with the name of the given CloudSecurityGroupvoid updateSecurityGroup(String name, InputStream jsonRulesFile)
cf
update-security-group SECURITY-GROUP PATH-TO-RULES-FILE when using the cf command line. See the Application Security Group
documentation for more details.
Example JSON-formatted rules file:
[
{
"protocol":"tcp",
"destination":"10.0.11.0/24",
"ports":"1-65535"
},
{
"protocol":"udp",
"destination":"10.0.11.0/24",
"ports":"1-65535"
}
]
This method requires the logged in user to have admin permissions in the cloud controller.jsonRulesFile - An input stream that has a single array with JSON objects inside describing the rulesCloudOperationException - if a security group does not exist with the given namehttp://docs.cloudfoundry.org/adminguide/app-sec-groups.htmlvoid updateServiceBroker(CloudServiceBroker serviceBroker)
serviceBroker - cloud service broker infovoid updateServicePlanVisibilityForBroker(String name, boolean visibility)
name - the service broker namevisibility - true for public, false for privatevoid uploadApplication(String applicationName, String file) throws IOException
applicationName - application namefile - path to the application archive or folderIOExceptionvoid uploadApplication(String applicationName, File file) throws IOException
applicationName - the application namefile - the application archive or folderIOExceptionvoid uploadApplication(String applicationName, File file, UploadStatusCallback callback) throws IOException
applicationName - the application namefile - the application archivecallback - a callback interface used to provide progress information or nullIOExceptionvoid uploadApplication(String applicationName, InputStream inputStream) throws IOException
applicationName - the application nameinputStream - the InputStream to read fromIOExceptionvoid uploadApplication(String applicationName, InputStream inputStream, UploadStatusCallback callback) throws IOException
applicationName - the application nameinputStream - the InputStream to read fromcallback - a callback interface used to provide progress information or nullIOExceptionUploadToken asyncUploadApplication(String applicationName, File file) throws IOException
IOExceptionUploadToken asyncUploadApplication(String applicationName, File file, UploadStatusCallback callback) throws IOException
IOExceptionList<CloudTask> getTasks(String applicationName)
applicationName - the application to look for tasksUnsupportedOperationException - if the targeted controller does not support tasksCloudTask runTask(String applicationName, CloudTask task)
applicationName - the application to run the task ontask - the task to runUnsupportedOperationException - if the targeted controller does not support tasksCloudTask cancelTask(UUID taskGuid)
taskGuid - the GUID of the task to cancelCloudBuild createBuild(UUID packageGuid)
CloudBuild getBuild(UUID buildGuid)
List<CloudBuild> getBuildsForApplication(UUID applicationGuid)
List<CloudBuild> getBuildsForPackage(UUID packageGuid)
List<CloudApplication> getApplicationsByMetadataLabelSelector(String labelSelector)
void updateApplicationMetadata(UUID guid, org.cloudfoundry.client.v3.Metadata metadata)
List<CloudService> getServicesByMetadataLabelSelector(String labelSelector)
void updateServiceMetadata(UUID guid, org.cloudfoundry.client.v3.Metadata metadata)
Copyright © 2020 SAP SE. All rights reserved.