summaryrefslogtreecommitdiffstats
path: root/common-app-api/src/main/java/org/openecomp
diff options
context:
space:
mode:
authorvasraz <vasyl.razinkov@est.tech>2021-11-26 14:40:29 +0000
committerMichael Morris <michael.morris@est.tech>2021-11-29 14:36:12 +0000
commit6c32cbc7343bd56f62007451071c4b26c875382f (patch)
treefa3250eb24d518e5f15cb629bdb462b96be769c5 /common-app-api/src/main/java/org/openecomp
parente9171113772c0c7dc3f7514ffd0660d1e0f8ef02 (diff)
Add VNFD to NSD when using S3 storage
Change-Id: I8eb810fadfe54b335647e71e21115514963b4be7 Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-3792
Diffstat (limited to 'common-app-api/src/main/java/org/openecomp')
-rw-r--r--common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java36
-rw-r--r--common-app-api/src/main/java/org/openecomp/sdc/be/csar/storage/ArtifactStorageManager.java4
2 files changed, 38 insertions, 2 deletions
diff --git a/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java b/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java
index 6ac82a547d..cabda08ce7 100644
--- a/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java
+++ b/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java
@@ -144,6 +144,7 @@ public class Configuration extends BasicConfiguration {
private EcompPortalConfig ecompPortal;
private List<ArtifactConfiguration> artifacts;
private Map<String, Map<String, List<String>>> componentAllowedInstanceTypes;
+ private ExternalCsarStore externalCsarStore;
@SuppressWarnings("unchecked")
private <K, V> Map<K, V> safeGetCapsInsensitiveMap(Map<K, V> map) {
@@ -165,8 +166,8 @@ public class Configuration extends BasicConfiguration {
public Map<String, Set<String>> getExcludedGroupTypesMapping() {
return safeGetCapsInsensitiveMap(excludedGroupTypesMapping);
}
-
- public List<Map<String, Map<String, String>>> getDefaultImports(){
+
+ public List<Map<String, Map<String, String>>> getDefaultImports() {
return Collections.unmodifiableList(defaultImports);
}
@@ -483,4 +484,35 @@ public class Configuration extends BasicConfiguration {
private String artifactType;
private List<PathsAndNamesDefinition> pathsAndNamesDefinitions;
}
+
+ @Getter
+ @Setter
+ @NoArgsConstructor
+ public static class ExternalCsarStore {
+
+ private String storageType;
+ private Endpoint endpoint;
+ private Credentials credentials;
+ private String tempPath;
+
+ @Getter
+ @Setter
+ @NoArgsConstructor
+ public static class Endpoint {
+
+ private String host;
+ private int port;
+ private boolean secure;
+ }
+
+ @Getter
+ @Setter
+ @NoArgsConstructor
+ public static class Credentials {
+
+ private String accessKey;
+ private String secretKey;
+ }
+ }
+
}
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 0a4f355642..f7d611b717 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
@@ -47,6 +47,8 @@ public interface ArtifactStorageManager {
*/
ArtifactInfo upload(String vspId, String versionId, InputStream fileToUpload);
+ void put(String vspId, String name, InputStream fileToUpload);
+
/**
* Checks if the Artifact Storage is enabled.
*
@@ -63,5 +65,7 @@ public interface ArtifactStorageManager {
InputStream get(final ArtifactInfo artifactInfo);
+ InputStream get(final String vspId, final String versionId);
+
void delete(ArtifactInfo artifactInfo);
}