From 115b2ef065fa652b380093e4f2571e53c3f0bc19 Mon Sep 17 00:00:00 2001 From: "andre.schmid" Date: Fri, 25 Mar 2022 19:30:14 +0000 Subject: Fix package storage and reducer config reload The package storage configuration was not being reloaded when a configuration file change was made. Increases OrchestrationTemplateCandidateImpl coverage by testing the upload to the artifact storage. Issue-ID: SDC-3934 Change-Id: I533b3c3a92cdadb60a375890da85ee053364e8af Signed-off-by: andre.schmid --- .../org/openecomp/sdc/be/csar/storage/ArtifactStorageManager.java | 1 + .../java/org/openecomp/sdc/be/csar/storage/PackageSizeReducer.java | 6 ++++++ 2 files changed, 7 insertions(+) (limited to 'common-app-api/src/main/java') diff --git a/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/ArtifactStorageManager.java b/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/ArtifactStorageManager.java index 9a4bc00162..1845f85e98 100644 --- a/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/ArtifactStorageManager.java +++ b/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/ArtifactStorageManager.java @@ -75,4 +75,5 @@ public interface ArtifactStorageManager { * @param vspId - VSP ID */ void delete(String vspId); + } diff --git a/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/PackageSizeReducer.java b/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/PackageSizeReducer.java index 290ca08d00..83fd8fdfbf 100644 --- a/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/PackageSizeReducer.java +++ b/common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/PackageSizeReducer.java @@ -27,6 +27,12 @@ import java.nio.file.Path; */ public interface PackageSizeReducer { + /** + * Reduces the package in the given path based on the package reducer configuration. + * + * @param path the package path + * @return the reduced package in bytes + */ byte[] reduce(Path path); } -- cgit 1.2.3-korg