Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ require (
gopkg.in/yaml.v3 v3.0.1 // indirect
)


// replace github.com/jfrog/build-info-go => github.com/jfrog/build-info-go v0.0.0-20241201000000-COMMIT_HASH

// replace github.com/jfrog/gofrog => github.com/jfrog/gofrog v1.7.6-0.20240909061051-2d36ae4bd05a
5 changes: 5 additions & 0 deletions lifecycle/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,11 @@ func (lcs *LifecycleServicesManager) ExportReleaseBundle(rbDetails lifecycle.Rel
return rbService.ExportReleaseBundle(rbDetails, modifications, queryParams)
}

func (lcs *LifecycleServicesManager) ExportReleaseBundleOnly(rbDetails lifecycle.ReleaseBundleDetails, modifications lifecycle.Modifications, queryParams lifecycle.CommonOptionalQueryParams) (exportResponse lifecycle.ReleaseBundleExportedStatusResponse, err error) {
rbService := lifecycle.NewReleaseBundlesService(lcs.config.GetServiceDetails(), lcs.client)
return rbService.ExportReleaseBundleOnly(rbDetails, modifications, queryParams)
}

func (lcs *LifecycleServicesManager) IsReleaseBundleExist(rbName, rbVersion, projectKey string) (bool, error) {
rbService := lifecycle.NewReleaseBundlesService(lcs.config.GetServiceDetails(), lcs.client)
return rbService.ReleaseBundleExists(rbName, rbVersion, projectKey)
Expand Down
17 changes: 17 additions & 0 deletions lifecycle/services/export.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,23 @@ func (rbs *ReleaseBundlesService) ExportReleaseBundle(rbDetails ReleaseBundleDet
return
}

func (rbs *ReleaseBundlesService) ExportReleaseBundleOnly(rbDetails ReleaseBundleDetails, modifications Modifications, queryParams CommonOptionalQueryParams) (exportResponse ReleaseBundleExportedStatusResponse, err error) {
// Check the current status
if exportResponse, err = rbs.getExportedReleaseBundleStatus(rbDetails, queryParams); err != nil {
return
}
if exportResponse.Status == ExportCompleted {
return
}
// Trigger export only, don't wait for completion
if err = rbs.triggerReleaseBundleExportProcess(rbDetails, modifications, queryParams); err != nil {
return
}
// Return current status after triggering export
exportResponse, err = rbs.getExportedReleaseBundleStatus(rbDetails, queryParams)
return
}

func (rbs *ReleaseBundlesService) waitForExport(rbDetails ReleaseBundleDetails, queryParams CommonOptionalQueryParams) (response ReleaseBundleExportedStatusResponse, err error) {
pollingAction := func() (shouldStop bool, responseBody []byte, err error) {
response, err = rbs.getExportedReleaseBundleStatus(rbDetails, queryParams)
Expand Down
Loading