Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents

SDC Component Diagram:

Sequence Diagram:

In this case, the Catalog plays a manager role of the workflows, it manage the designed workflows and  provide the Create/Updata/Query actions for workflows.

At the same time, the '(ZTE) WF Designer' plays an editor role of a workflow selected.

The interaction between Catalog and '(ZTE) WF Designer'  is as follows:

So, the rest APIs of Catalog should be provide by Amdocs/AT&T as follow:

  1. Get workflow JSON by WF ID

  2. Get Extend BPMN Activities (from Catalog)

  3. Get Detail Information of a BPMN Activity (from Catalog)

  4. Save workflow JSON with WF ID (to Catalog)

  5. Store BPMN Artifact against WF ID:


The rest APIs of '(ZTE) WF Designer' should be provided by ZTE as follow:

  1. Open and Navigates to (ZTE) WF Designer
  2. Generate WF ID(s) BPMN Artifact

Rest APIs of (ZTE) WF Designer (Workflow Editor) :

Rest API definitions of (ZTE) WF Designer, these APIs will be provided by ZTE.

Open and Navigates to (ZTE) WF Designer:

Open the an existed workflow and navigate to the '(ZTE) WF Designer'.

For a new workflow, before it be opened, the catalog(workflow manager) should create it first.  The Sequence Diagram shows as follow:

URL:

Code Block
languagebash
Get http://{wf-designer-ip}:{port}/workflow-modeler

Request:

Query Parameters:

NameData TypeRequiredDescriptionComment
idStringYesUnique UUID of the workflow
operationEnumYes

The operation for the workflow, Valid value as follow:

view - can view only, can't modify.

modify - can view and modify both.


Response:

Navigate to the (ZTE) WF Designer, load the workflow data with the given id from Catalog (Workflow Manager).

Generate WF ID(s) BPMN Artifact:

First, The generator call query API (see: Get workflow JSON by WF ID) to retrieve the json content of the workflow from Catalog.

Secend, The generator convert the data of the workflow from json format to BPMN format.

After then, the generator call save API (see: Store BPMN Artifact against WF ID) to save the BPMN content back to the  Catalog.

The Sequence for Generate BPMN Artifacts with WF ID(s) as follow:

Sequence Diagram, Rest API and Data Information for this Requirement

URL:

Code Block
languagebash
POST http://{wf-designer-ip}:{port}/api/workflow-modeler/v1/generateBPMN

Request:

Body Parameters:

NameData TypeRequiredDescriptionComment
idsString[]Yesids of the workflows need to generate the BPMN Artifacts.

Response:

NameData TypeRequiredDescriptionComment
idsString[]Yesids of the workflows generated BPMN Artifacts successfully.



Rest APIs of Catalog (Workflow Manager):

Rest API definitions of Catalog (Workflow Manager), these APIs will be provided by Amdocs/AT&T.

Get workflow JSON by WF ID:

URL:

Code Block
languagebash
GET http://{sdc-ip}:{port}/api/sdc/v1/workflow-modeler/models/{id}

Request:

Path Parameters:

NameData TypeRequiredDescriptionComment
idStringYesUnique UUID of the workflow

Response:

Return the information of the workflow in json format. see Sequence Diagram, Rest API and Data Information for this Requirement: for details.

Get Extend BPMN Activities (from Catalog):

Get the extend Activities such as 'Stop Traffic', 'Stop VNF', 'Create VNF', etc.

URL:

Code Block
languagebash
GET http://{sdc-ip}:{port}/api/sdc/v1/workflow-modeler/ext-activities

Request:

Query Parameters:

NameData TypeRequiredDescriptionComment
sceneEnumYes

the scene of the workflow designer. Valid value as follow:

resource - open a VNF's workflow

service - open a Service's workflow

different scene may has different activities extend.

Response:

NameData TypeRequiredDescriptionComment
activities
ExtendActivityBriefInfo[]
Yes
extend activity brief information list

Get Detail Information of a BPMN Activity (from Catalog):

URL:

Code Block
languagebash
GET http://{sdc-ip}:{port}/api/sdc/v1/workflow-modeler/ext-activities/{id}

Request:

Path Parameters:

NameData TypeRequiredDescriptionComment
id
StringYes

Uniqued id of the extend bpmn activity.


Response:

Return the detail information of the extend activity. see ExtendActivity for details.


Save workflow JSON with WF ID (to Catalog):

URL:

Code Block
languagebash
PUT http://{sdc-ip}:{port}/api/sdc/v1/workflow-modeler/models/{id}

Request:

Pah Parameters:

NameData TypeRequiredDescriptionComment
idStringYesUnique UUID of the workflow

Body Parameters:

The information of the workflow in json format, see Sequence Diagram, Rest API and Data Information for this Requirement: for details.

Response:

NameData TypeRequiredDescriptionComment
idStringYesUnique UUID of the workflow saved

Store BPMN Artifact against WF ID:

URL:

Code Block
languagebash
PUT http://{sdc-ip}:{port}/api/sdc/v1/workflow-modeler/models/{id}/bpmn

Request:

Path Parameters:

NameData TypeRequiredDescriptionComment
idStringYesUnique UUID of the workflow

Body Parameters:

NameData TypeRequiredDescriptionComment
idStringYesUnique UUID of the workflow
nameStringYesName for the workflow
bpmnDataStringYesContnent of workflow in bpmn format

Response:

NameData TypeRequiredDescriptionComment
idStringYesUnique UUID of the workflow saved


Data Information?

WorkflowInfo:

NameData TypeRequiredDescriptionComment
id
String
Yes
Unique UUID of the workflow

name
String
YesName of the workflow
version
String
Noversion of the workflow
description
String
Nodescription of the workflow
sceneEnumYes

the scene of the workflow designer. Valid value as follow:

resource - open a VNF's workflow

service - open a Service's workflow

different scene may has different activities extend.
data
String
YesContnent of the workflow in json format


ExtendActivityBriefInfo:

Brief informtion of the extend activity.

Name

Data Type

Required

Description

Comment

id

String

Yes

id of the activity


name

String

Yes

name of the activity


description

String

No

name of the activity
category

String

No

Categorization to help better experience to the Designer while building the work-flow


svgStringYesthe icon to show

ExtendActivity:

Detail informtion of the extend activity.

Name

Data Type

Required

Description

Comment

id

String

Yes

id of the activity


name

String

Yes

name of the activity


description

String

No

description of the activity

category

String

No

Categorization to help better experience to the Designer while building the work-flow


type

Enum

Yes

activity type, valid values as follow:

java - Service(Java) Task

script - Script Task

rest - Rest Task


activityJavaTask|ScriptTask|RestTaskYes

Type related bpmn task information of the activity. These information will be used by the workflow engine.

JavaTask for Service(Java) Task, ScriptTask for Script Task, RestTask for Rest Task.

JavaTask:

Name

Data Type

Required

Description

Comment

classStringYesThe implement class of the bpmn service task

inputs

Input[]

No

The input parameter definitions of the service task. These parameters will dispaly on UI for designer to fullfill.
mappingInputsMappingInput[]NoThe mapping input parameter definitions of the service task. These parameters will tranform to the actual input parameters of the service task which will be executed on the workflow engine.Only define the relationshipe between the actual input parameter and the UI dispalyed input parameter of the bpmn task.

ScriptTask:

Name

Data Type

Required

Description

Comment

format

String

Yes

The default script format, For example: javascript groovy


script

String

Yes

The default script content.


RestTask:

Name

Data Type

Required

Description

Comment

url

String

No

The URL of the REST API exposed through the API router.

Choose between the 'url' field and ('name', 'version') filed.
nameStringNo

The microservcie name of the REST API.

Only for the condition of access the REST API via MircoServiceBus.


versionStringNo

The microservcie version of the REST API.

Only for the condition of access the REST API via MircoServiceBus.

In the condition of access the REST API via MircoServiceBus, The workflow engine can query the URL of the REST API exposed through the MircoServiceBus by name and version.
pathStringYesThe path of the REST API relative to the API router exposed path.

method

Enum

Yes

The method of the rest api to be called while the activity be executed on the workflow engine.

Valid value as follow: get, post, put, delete


headers

Map<Strting, String>

Yes

The header paramters of the rest api associated to the rest task.

Map key is the header paramter name, such as 'Accept'.Map value is the header paramter name, such as ''application/json.



inputs

Input[]

No

The input parameter definitions of the rest task. These parameters will dispaly on UI for designer to fullfill.
mappingInputsMappingInput[]NoThe mapping input parameter definitions of the rest task. These parameters will tranform to the actual input parameters of the rest task which will be executed on the workflow engine.Only define the relationshipe between the actual input parameter and the UI dispalyed input parameter of the bpmn task.

Input:

Name

Data Type

Required

Description

Comment

name

String

Yes

Input paramter name


dataType

Enum

Yes

data type of the input paramter. Valid value as follow:

string, integer, float, boolean, enum


required

boolean

Yes

Should the input paramter be necessary?

true - necessary

false - not necessary


default

any

No

the default value of the input paramter.


enumValue

String[]

No

the enum value of the paramter.

only need when the dataType of the paramter is 'enum'.


MappingInput:

Define the relationshipe between the actual input parameter and the UI dispalyed input parameter of the bpmn task.

Name

Data Type

Required

Description

Comment

name

String

Yes

The actual parameter name of the bpmn task.


valueTypeEnumYes

Type of the 'Value' field, Valid Value as follow:

fixed - fixed value, suck as 'abc', 123

reference - name of the UI displayed parameter referenced


valueanyNo

fixed value or UI displayed parameter name referenced. such as:

"abc" –fixed

123 --fixed

true –fixed

[Name] - UI displayed parameter name