@Validated
public interface ApplicationService
| Modifier and Type | Method and Description |
|---|---|
void |
addConfigsToApplication(java.lang.String id,
java.util.Set<java.lang.String> configs)
Add a configuration file to the application.
|
void |
addDependenciesForApplication(java.lang.String id,
java.util.Set<java.lang.String> dependencies)
Add dependency files to the application.
|
void |
addTagsForApplication(java.lang.String id,
java.util.Set<java.lang.String> tags)
Add tags to the application.
|
java.lang.String |
createApplication(Application app)
Create new application.
|
void |
deleteAllApplications()
Delete all applications from database.
|
void |
deleteApplication(java.lang.String id)
Delete an application configuration from database.
|
Application |
getApplication(java.lang.String id)
Gets application for given id.
|
org.springframework.data.domain.Page<Application> |
getApplications(java.lang.String name,
java.lang.String user,
java.util.Set<ApplicationStatus> statuses,
java.util.Set<java.lang.String> tags,
java.lang.String type,
org.springframework.data.domain.Pageable pageable)
Get applications for given filter criteria.
|
java.util.Set<Command> |
getCommandsForApplication(java.lang.String id,
java.util.Set<CommandStatus> statuses)
Get all the commands the application with given id is associated with.
|
java.util.Set<java.lang.String> |
getConfigsForApplication(java.lang.String id)
Get the set of configuration files associated with the application with
given id.
|
java.util.Set<java.lang.String> |
getDependenciesForApplication(java.lang.String id)
Get the set of dependency files associated with the application with given id.
|
java.util.Set<java.lang.String> |
getTagsForApplication(java.lang.String id)
Get the set of tags associated with the application with given
id.
|
void |
patchApplication(java.lang.String id,
com.github.fge.jsonpatch.JsonPatch patch)
Patch an application with the given json patch.
|
void |
removeAllConfigsForApplication(java.lang.String id)
Remove all configuration files from the application.
|
void |
removeAllDependenciesForApplication(java.lang.String id)
Remove all dependency files from the application.
|
void |
removeAllTagsForApplication(java.lang.String id)
Remove all tags from the application.
|
void |
removeConfigForApplication(java.lang.String id,
java.lang.String config)
Remove a configuration file from the application.
|
void |
removeDependencyForApplication(java.lang.String id,
java.lang.String dependency)
Remove a dependency file from the application.
|
void |
removeTagForApplication(java.lang.String id,
java.lang.String tag)
Remove a tag from the application.
|
void |
updateApplication(java.lang.String id,
Application updateApp)
Update an application.
|
void |
updateConfigsForApplication(java.lang.String id,
java.util.Set<java.lang.String> configs)
Update the set of configuration files associated with the application
with given id.
|
void |
updateDependenciesForApplication(java.lang.String id,
java.util.Set<java.lang.String> dependencies)
Update the set of dependency files associated with the application with given
id.
|
void |
updateTagsForApplication(java.lang.String id,
java.util.Set<java.lang.String> tags)
Update the set of tags associated with the application with
given id.
|
java.lang.String createApplication(@NotNull(message="No application entered to create.")
Application app)
throws GenieException
app - The application configuration to createGenieException - if there is an errorApplication getApplication(@NotBlank(message="No id entered. Unable to get") java.lang.String id) throws GenieException
id - unique id for application configuration to get. Not null/empty.GenieException - if there is an errororg.springframework.data.domain.Page<Application> getApplications(java.lang.String name, java.lang.String user, java.util.Set<ApplicationStatus> statuses, java.util.Set<java.lang.String> tags, java.lang.String type, org.springframework.data.domain.Pageable pageable)
name - Name of application. Can be null or empty.user - The user who created the application. Can be null/emptystatuses - The statuses of the applications to find. Can be null.tags - Tags allocated to this applicationtype - The type of the application to findpageable - The page requested from the search resultsvoid updateApplication(@NotBlank(message="No application id entered. Unable to update.")
java.lang.String id,
@NotNull(message="No application information entered. Unable to update.")
Application updateApp)
throws GenieException
id - The id of the application configuration to updateupdateApp - Information to update for the application configuration
withGenieException - if there is an errorvoid patchApplication(@NotBlank
java.lang.String id,
@NotNull
com.github.fge.jsonpatch.JsonPatch patch)
throws GenieException
id - The id of the application to updatepatch - The json patch to use to update the given applicationGenieException - if there is an errorvoid deleteAllApplications()
throws GenieException
GenieException - if there is an errorvoid deleteApplication(@NotBlank(message="No application id entered. Unable to delete.")
java.lang.String id)
throws GenieException
id - unique id of application configuration to deleteGenieException - if there is an errorvoid addConfigsToApplication(@NotBlank(message="No application id entered. Unable to add configurations.")
java.lang.String id,
@NotEmpty(message="No configuration files entered.")
java.util.Set<java.lang.String> configs)
throws GenieException
id - The id of the application to add the configuration file to. Not
null/empty/blank.configs - The configuration files to add. Not null/empty.GenieException - if there is an errorjava.util.Set<java.lang.String> getConfigsForApplication(@NotBlank(message="No application id entered. Unable to get configs.")
java.lang.String id)
throws GenieException
id - The id of the application to get the configuration files for.
Not null/empty/blank.GenieException - if there is an errorvoid updateConfigsForApplication(@NotBlank(message="No application id entered. Unable to update configurations.")
java.lang.String id,
@NotNull(message="No configs entered. Unable to update. If you want, use delete API.")
java.util.Set<java.lang.String> configs)
throws GenieException
id - The id of the application to update the configuration files
for. Not null/empty/blank.configs - The configuration files to replace existing configurations
with. Not null/empty.GenieException - if there is an errorvoid removeAllConfigsForApplication(@NotBlank(message="No application id entered. Unable to remove configs.")
java.lang.String id)
throws GenieException
id - The id of the application to remove the configuration file
from. Not null/empty/blank.GenieException - if there is an errorvoid removeConfigForApplication(@NotBlank(message="No application id entered. Unable to remove configuration.")
java.lang.String id,
@NotBlank(message="No config entered. Unable to remove.")
java.lang.String config)
throws GenieException
id - The id of the application to remove the configuration file
from. Not null/empty/blank.config - The configuration file to remove. Not null/empty/blank.GenieException - if there is an errorvoid addDependenciesForApplication(@NotBlank(message="No application id entered. Unable to add dependencies.")
java.lang.String id,
@NotEmpty(message="No dependencies entered. Unable to add dependencies.")
java.util.Set<java.lang.String> dependencies)
throws GenieException
id - The id of the application to add the dependency file to. Not
null/empty/blank.dependencies - The dependency files to add. Not null.GenieException - if there is an errorjava.util.Set<java.lang.String> getDependenciesForApplication(@NotBlank(message="No application id entered. Unable to get dependencies.")
java.lang.String id)
throws GenieException
id - The id of the application to get the dependency files for. Not
null/empty/blank.GenieException - if there is an errorvoid updateDependenciesForApplication(@NotBlank(message="No application id entered. Unable to update dependencies.")
java.lang.String id,
@NotNull(message="No dependencies entered. Unable to update.")
java.util.Set<java.lang.String> dependencies)
throws GenieException
id - The id of the application to update the dependency files for. Not
null/empty/blank.dependencies - The dependency files to replace existing dependencies with. Not null/empty.GenieException - if there is an errorvoid removeAllDependenciesForApplication(@NotBlank(message="No application id entered. Unable to remove dependencies.")
java.lang.String id)
throws GenieException
id - The id of the application to remove the configuration file
from. Not null/empty/blank.GenieException - if there is an errorvoid removeDependencyForApplication(@NotBlank(message="No application id entered. Unable to remove dependency.")
java.lang.String id,
@NotBlank(message="No dependency entered. Unable to remove dependency.")
java.lang.String dependency)
throws GenieException
id - The id of the application to remove the dependency file from. Not
null/empty/blank.dependency - The dependency file to remove. Not null/empty/blank.GenieException - if there is an errorvoid addTagsForApplication(@NotBlank(message="No application id entered. Unable to add tags.")
java.lang.String id,
@NotEmpty(message="No tags entered. Unable to add.")
java.util.Set<java.lang.String> tags)
throws GenieException
id - The id of the application to add the tags to. Not
null/empty/blank.tags - The tags to add. Not null/empty.GenieException - if there is an errorjava.util.Set<java.lang.String> getTagsForApplication(@NotBlank(message="No application id entered. Cannot retrieve tags.")
java.lang.String id)
throws GenieException
id - The id of the application to get the tags for. Not
null/empty/blank.GenieException - if there is an errorvoid updateTagsForApplication(@NotBlank(message="No application id entered. Unable to update tags.")
java.lang.String id,
@NotNull(message="No tags entered unable to update tags.")
java.util.Set<java.lang.String> tags)
throws GenieException
id - The id of the application to update the tags for.
Not null/empty/blank.tags - The tags to replace existing tags
with. Not null/empty.GenieException - if there is an errorvoid removeAllTagsForApplication(@NotBlank(message="No application id entered. Unable to remove tags.")
java.lang.String id)
throws GenieException
id - The id of the application to remove the tags from.
Not null/empty/blank.GenieException - if there is an errorvoid removeTagForApplication(@NotBlank(message="No application id entered. Unable to remove tag.")
java.lang.String id,
@NotBlank(message="No tag entered. Unable to remove.")
java.lang.String tag)
throws GenieException
id - The id of the application to remove the tag from. Not
null/empty/blank.tag - The tag to remove. Not null/empty/blank.GenieException - if there is an errorjava.util.Set<Command> getCommandsForApplication(@NotBlank(message="No application id entered. Unable to get commands.") java.lang.String id, java.util.Set<CommandStatus> statuses) throws GenieException
id - The id of the application to get the commands for.statuses - The status of the commands returnedGenieException - if there is an error