public class AppRegistryTemplate extends Object implements AppRegistryOperations
AppRegistryOperations that uses RestTemplate
to issue commands to the Data Flow server.| Modifier and Type | Field and Description |
|---|---|
protected RestTemplate |
restTemplate
Template used for http interaction.
|
| Constructor and Description |
|---|
AppRegistryTemplate(RestTemplate restTemplate,
org.springframework.hateoas.ResourceSupport resourceSupport)
Construct a
AppRegistryTemplate object. |
| Modifier and Type | Method and Description |
|---|---|
org.springframework.hateoas.PagedResources<AppRegistrationResource> |
importFromResource(String uri,
boolean force)
Register all applications listed in a properties file.
|
DetailedAppRegistrationResource |
info(String name,
ApplicationType type)
Retrieve information about an application registration.
|
org.springframework.hateoas.PagedResources<AppRegistrationResource> |
list()
Return a list of all application registrations.
|
org.springframework.hateoas.PagedResources<AppRegistrationResource> |
list(ApplicationType type)
Return a list of all application registrations for the given
ApplicationType. |
AppRegistrationResource |
register(String name,
ApplicationType type,
String uri,
boolean force)
Register an application name and type with its Maven coordinates.
|
org.springframework.hateoas.PagedResources<AppRegistrationResource> |
registerAll(Properties apps,
boolean force)
Register all applications provided as key/value pairs.
|
void |
unregister(String name,
ApplicationType applicationType)
Unregister an application name and type.
|
protected RestTemplate restTemplate
public AppRegistryTemplate(RestTemplate restTemplate, org.springframework.hateoas.ResourceSupport resourceSupport)
AppRegistryTemplate object.restTemplate - template for HTTP/rest commandsresourceSupport - HATEOAS link supportpublic org.springframework.hateoas.PagedResources<AppRegistrationResource> list()
AppRegistryOperationslist in interface AppRegistryOperationspublic org.springframework.hateoas.PagedResources<AppRegistrationResource> list(ApplicationType type)
AppRegistryOperationsApplicationType.list in interface AppRegistryOperationstype - application type for which to return a list of registrationspublic void unregister(String name, ApplicationType applicationType)
AppRegistryOperationsunregister in interface AppRegistryOperationsname - application nameapplicationType - application typepublic DetailedAppRegistrationResource info(String name, ApplicationType type)
AppRegistryOperationsinfo in interface AppRegistryOperationsname - name of applicationtype - application typepublic AppRegistrationResource register(String name, ApplicationType type, String uri, boolean force)
AppRegistryOperationsregister in interface AppRegistryOperationsname - application nametype - application typeuri - URI for the application artifactforce - if true, overwrites a pre-existing registrationpublic org.springframework.hateoas.PagedResources<AppRegistrationResource> importFromResource(String uri, boolean force)
AppRegistryOperationsimportFromResource in interface AppRegistryOperationsuri - URI for the properties fileforce - if true, overwrites any pre-existing registrationspublic org.springframework.hateoas.PagedResources<AppRegistrationResource> registerAll(Properties apps, boolean force)
AppRegistryOperationsregisterAll in interface AppRegistryOperationsapps - the apps as key/value pairs where key is "type.name" and value is a URIforce - if true, overwrites any pre-existing registrationsCopyright © 2016 Pivotal Software, Inc.. All rights reserved.