From b3f740bf6a2a5e52ea1283459067a0790d86701e Mon Sep 17 00:00:00 2001 From: Michael Sverdlov Date: Thu, 19 Sep 2024 14:40:22 +0300 Subject: [PATCH] Make failFast upload service param public (#1025) --- README.md | 6 +++--- artifactory/manager.go | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index f1722d8f9..917aa727d 100644 --- a/README.md +++ b/README.md @@ -229,7 +229,7 @@ - [Delete Release Bundle Version](#delete-release-bundle-version) - [Delete Release Bundle Version Promotion](#delete-release-bundle-version-promotion) - [Export Release Bundle Archive](#export-release-bundle-archive) - - [Import Release Bundle](#import-release-bundle) + - [Import Release Bundle Archive](#import-release-bundle-archive) - [Remote Delete Release Bundle](#remote-delete-release-bundle) - [Lifecycle APIs](#lifecycle-apis) - [Creating Lifecycle Service Manager](#creating-lifeCycle-service-manager) @@ -472,8 +472,8 @@ TargetPathInArchive := "archive/path/" SizeLimit= &fspatterns.SizeThreshold{SizeInBytes: 10000, Condition: fspatterns.LessThan} uploadServiceOptions := &UploadServiceOptions{ -// Set to true to fail the upload operation if any of the files fail to upload -FailFast: false, + // Set to true to fail the upload operation if any of the files fail to upload + FailFast: false, } totalUploaded, totalFailed, err := rtManager.UploadFiles(uploadServiceOptions, params) diff --git a/artifactory/manager.go b/artifactory/manager.go index f79409e8f..3b1172b90 100644 --- a/artifactory/manager.go +++ b/artifactory/manager.go @@ -304,7 +304,7 @@ func (sm *ArtifactoryServicesManagerImp) GetItemProps(relativePath string) (*uti type UploadServiceOptions struct { // Fail the operation immediately if an error occurs. - failFast bool + FailFast bool } func (sm *ArtifactoryServicesManagerImp) initUploadService(uploadServiceOptions UploadServiceOptions) *services.UploadService { @@ -312,7 +312,7 @@ func (sm *ArtifactoryServicesManagerImp) initUploadService(uploadServiceOptions uploadService.Threads = sm.config.GetThreads() uploadService.ArtDetails = sm.config.GetServiceDetails() uploadService.DryRun = sm.config.IsDryRun() - uploadService.SetFailFast(uploadServiceOptions.failFast) + uploadService.SetFailFast(uploadServiceOptions.FailFast) uploadService.Progress = sm.progress httpClientDetails := uploadService.ArtDetails.CreateHttpClientDetails() uploadService.MultipartUpload = utils.NewMultipartUpload(sm.client, &httpClientDetails, uploadService.ArtDetails.GetUrl())