public class ReleaseService extends Object
ReleaseManager
Constructor and Description |
---|
ReleaseService(PackageMetadataRepository packageMetadataRepository,
ReleaseRepository releaseRepository,
PackageService packageService,
ReleaseManagerFactory releaseManagerFactory,
DeployerRepository deployerRepository,
PackageMetadataService packageMetadataService) |
Modifier and Type | Method and Description |
---|---|
protected Release |
createInitialRelease(InstallProperties installProperties,
Package packageToInstall,
int releaseVersion) |
protected Info |
createNewInfo() |
ReleaseAnalysisReport |
createReport(Release existingRelease,
Release replacingRelease) |
Release |
delete(String releaseName)
Delete the release.
|
Release |
delete(String releaseName,
boolean deleteReleasePackage)
If the deleteReleasePackage is true deletes the release along with the package it was created from.
|
List<Release> |
history(String releaseName,
int maxRevisions)
List the history of versions for a given release.
|
Release |
install(InstallRequest installRequest)
Downloads the package metadata and package zip file specified by PackageIdentifier
property of the DeploymentRequest.
|
Release |
install(Long id,
InstallProperties installProperties)
Downloads the package metadata and package zip file specified by the given Id and
deploys the package on the target platform.
|
protected Release |
install(PackageMetadata packageMetadata,
InstallProperties installProperties) |
Release |
install(Release release) |
List<Release> |
list()
Get the latest revision of all releases with status of deployed or failed state.
|
List<Release> |
list(String releaseNameLike)
List the latest version of releases with status of deployed or failed.
|
Manifest |
manifest(String releaseName)
Return the manifest, the final set of instructions to deploy for a given release.
|
Manifest |
manifest(String releaseName,
Integer version)
Return the manifest, the final set of instructions to deploy for a given release, given
the name and version.
|
Info |
status(String releaseName)
Return the current status of the release
|
Info |
status(String releaseName,
Integer version)
Return the current status of the release given the release and version.
|
protected void |
validateInitialRelease(Release release)
Do up front checks before deploying
|
public ReleaseService(PackageMetadataRepository packageMetadataRepository, ReleaseRepository releaseRepository, PackageService packageService, ReleaseManagerFactory releaseManagerFactory, DeployerRepository deployerRepository, PackageMetadataService packageMetadataService)
@Transactional public Release install(Long id, InstallProperties installProperties)
id
- of the packageinstallProperties
- contains the name of the release, the platfrom to install to,
and configuration values to replace in the package template.SkipperException
- if the package to install can not be found.@Transactional public Release install(InstallRequest installRequest)
installRequest
- the install requestprotected Release install(PackageMetadata packageMetadata, InstallProperties installProperties)
@Transactional public Release delete(String releaseName)
releaseName
- the name of the release@Transactional public Release delete(String releaseName, boolean deleteReleasePackage)
delete(String)
releaseName
- the name of the release to be deleteddeleteReleasePackage
- if true tries to delete the package of the releaseName release@Transactional public Info status(String releaseName)
releaseName
- the name of the release@Transactional public Info status(String releaseName, Integer version)
releaseName
- name of the releaseversion
- release version@Transactional public Manifest manifest(String releaseName)
releaseName
- the name of the release@Transactional public Manifest manifest(String releaseName, Integer version)
releaseName
- the name of the releaseversion
- the release versionprotected Info createNewInfo()
@Transactional public ReleaseAnalysisReport createReport(Release existingRelease, Release replacingRelease)
protected Release createInitialRelease(InstallProperties installProperties, Package packageToInstall, int releaseVersion)
protected void validateInitialRelease(Release release)
release
- the initial release object this data provided by the end user.@Transactional public List<Release> history(String releaseName, int maxRevisions)
releaseName
- the release name of the release to search formaxRevisions
- the maximum number of revisions to get@Transactional public List<Release> list(String releaseNameLike)
releaseNameLike
- the wildcard name of releases to search forCopyright © 2018 Pivotal Software, Inc.. All rights reserved.