Uploaded image for project: 'Service Design and Creation'
  1. Service Design and Creation
  2. SDC-2960

Cannot add external workflow to an operation

XMLWordPrintable

      When creating an Operation with a external workflow, in any Component (e.g. VF, Service), SDC throws an error 400.

      The call that causes it the following, which I believe to be trying to upload the provided Workflow.

      curl 'http://localhost:8285/sdc1/feProxy/rest/v1/catalog/resources/3c4bfd8a-0ef3-4b21-a55c-5be557e2c1e6/interfaces/635b3b12-88fe-4254-8ceb-620d59a422b3/operations/a819b602-ef90-4801-b139-9dca3ef1799a/artifacts/6a9f00c5-39b1-4459-90f3-f9ef40bf56f0' \
        -H 'Connection: keep-alive' \
        -H 'USER_ID: cs0008' \
        -H 'Accept: application/json, text/plain, */*' \
        -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.92 Safari/537.36' \
        -H 'Content-Type: application/json; charset=UTF-8' \
        -H 'Origin: http://localhost:8285' \
        -H 'Sec-Fetch-Site: same-origin' \
        -H 'Sec-Fetch-Mode: cors' \
        -H 'Sec-Fetch-Dest: empty' \
        -H 'Referer: http://localhost:8285/sdc1' \
        -H 'Accept-Language: en,pt-BR;q=0.9,pt;q=0.8,en-US;q=0.7' \
        -H 'Cookie: JSESSIONID=node01ffr895rnmv511398cztt9d50f2.node0; HTTP_IV_REMOTE_ADDRESS=0.0.0.0; HTTP_CSP_WSTYPE=Intranet; Idea-7b48a367=a4b60d75-8e49-4577-9295-9778c96141d8; HTTP_IV_USER=cs0008; HTTP_CSP_FIRSTNAME=Carlos; HTTP_CSP_LASTNAME=Santana; USER_ID=cs0008; Idea-a734b789=2d9cd438-ae6a-4e45-9777-2ad3d137a450; JSESSIONID.2f313dab=node015xcu8n9kyey91vef7bafe7e541.node0; screenResolution=2560x1080; adminer_key=e67a1d827456f5dd6bf347f4785562d8; adminer_permanent=; adminer_sid=f8b6f0b3c4b7092861192b2cc29459cf; HTTP_CSP_EMAIL=designer%40sdc.com; EPService=randomValue; JSESSIONID=node063y6a8iwfpam1xgrivjkoc65f63.node0' \
        --data-binary '{"artifactType":"WORKFLOW","artifactName":"workflow2-1.0.bpmn","description":"Workflow Artifact Description","payloadData":"a-artifact-payload"}' \
        --compressed 

      This is probably due to a missing "md5 header", the exception is thrown at org.openecomp.sdc.be.components.impl.ArtifactsBusinessLogic#validateMd5

      if (ArrayUtils.isNotEmpty(payload)) {
          log.debug("Cannot have payload while md5 header is missing");
          throw new ByActionStatusComponentException(ActionStatus.INVALID_CONTENT);
      } 

      Also the operation is created, even with the failure.

            Unassigned Unassigned
            andre.schmid andre.schmid
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: