From 049d078d8abbe637b213a2f14c2192379208c168 Mon Sep 17 00:00:00 2001 From: "andre.schmid" Date: Wed, 15 Dec 2021 19:44:06 +0000 Subject: Onboarding upload control Brings the initial structure to control asynchronously a VSP package upload during the onboarding. Instead of blocking the UI, the upload and processing status will be controlled by the backend, so the frontend can query it and control the behaviour of the UI. Updates the upload endpoint to obtain/verify an upload lock, and creates a second endpoint to check for the upload status. Change-Id: If1c43fb4f0b11e1d8a5627578bafc75f266393c2 Issue-ID: SDC-3826, SDC-3827 Signed-off-by: andre.schmid --- .../sdc/be/csar/storage/MinIoArtifactInfo.java | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'common-be') diff --git a/common-be/src/main/java/org/openecomp/sdc/be/csar/storage/MinIoArtifactInfo.java b/common-be/src/main/java/org/openecomp/sdc/be/csar/storage/MinIoArtifactInfo.java index a193cdd6db..f5e26ab2b6 100644 --- a/common-be/src/main/java/org/openecomp/sdc/be/csar/storage/MinIoArtifactInfo.java +++ b/common-be/src/main/java/org/openecomp/sdc/be/csar/storage/MinIoArtifactInfo.java @@ -20,19 +20,33 @@ package org.openecomp.sdc.be.csar.storage; -import lombok.AllArgsConstructor; import lombok.Getter; -@AllArgsConstructor @Getter public class MinIoArtifactInfo implements ArtifactInfo { private final String bucket; private final String objectName; + private byte[] artifactBytes; + + public MinIoArtifactInfo(final String bucket, final String objectName) { + this.bucket = bucket; + this.objectName = objectName; + } @Override public String getInfo() { return String.format("bucket: %s\n" + "object: %s", bucket, objectName); } + + @Override + public byte[] getBytes() { + return artifactBytes; + } + + @Override + public void setBytes(final byte[] artifactBytes) { + this.artifactBytes = artifactBytes; + } } -- cgit 1.2.3-korg