generated from SAP/repository-template
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: add documentation for the new process
Refs: #79
- Loading branch information
Showing
7 changed files
with
247 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
# Create Technical User Process | ||
|
||
## Summary | ||
|
||
The create wallet process handles the creation of a wallet. The process steps are the following: | ||
|
||
```mermaid | ||
flowchart TD | ||
A(CREATE_WALLET) -->|Success| B(CHECK_OPERATION) | ||
B -->|Success| C(GET_COMPANY) | ||
C -->|Success| D(GET_DID_DOCUMENT) | ||
D -->|Success| E(CREATE_STATUS_LIST) | ||
E -->|Success| F(SEND_CALLBACK) | ||
A-->|Error| G(RETRIGGER_CREATE_WALLET) | ||
B-->|Error| H(RETRIGGER_CHECK_OPERATION) | ||
C-->|Error| I(RETRIGGER_GET_COMPANY) | ||
D-->|Error| J(RETRIGGER_GET_DID_DOCUMENT) | ||
E-->|Error| K(RETRIGGER_CREATE_STATUS_LIST) | ||
F-->|Error| L(RETRIGGER_SEND_CALLBACK) | ||
G--> A | ||
H--> B | ||
I--> C | ||
J--> D | ||
K--> E | ||
L--> F | ||
``` | ||
|
||
## External dependencies | ||
|
||
The process worker communicates with the SAP Dim to create the technical user. It further more communicates with the portal backend to return the technical user data. | ||
|
||
## Process Steps | ||
|
||
### CREATE_WALLET | ||
|
||
The process step `CREATE_WALLET` is automatically triggered from the process worker. It sends a request to create the wallet to the SAP Dim. | ||
|
||
### CHECK_OPERATION | ||
|
||
The process step `CHECK_OPERATION` is automatically triggered from the process worker. It requests the status of the operation which is created in the `CREATE_WALLET` step. If the status is `completed` it takes the data of the wallet and saves it in the database. | ||
|
||
### GET_COMPANY | ||
|
||
The process step `GET_COMPANY` is automatically triggered from the process worker. It retrieves Did download url and company id and saves it to the database. | ||
|
||
### GET_DID_DOCUMENT | ||
|
||
The process step `GET_DID_DOCUMENT` is automatically triggered from the process worker. It retrieves the did and saves it to the database. | ||
|
||
### CREATE_STATUS_LIST | ||
|
||
The process step `CREATE_STATUS_LIST` is automatically triggered from the process worker if the wallet is created for the issuer. It creates a status list. | ||
|
||
### SEND_CALLBACK | ||
|
||
The process step `SEND_CALLBACK` is automatically triggered from the process worker. It sends the wallet data, did and the did document to the portal backend. | ||
|
||
## Retrigger | ||
|
||
| Step Name | Retrigger Step | Retrigger Endpoint | | ||
| ------------------ | ---------------------------- | ------------------------------------------------------------------------------------------- | | ||
| CREATE_WALLET | RETRIGGER_CREATE_WALLET | api/dim/process/wallet/{processId}/retrigger?processStepTypeId=RETRIGGER_CREATE_WALLET | | ||
| CHECK_OPERATION | RETRIGGER_CHECK_OPERATION | api/dim/process/wallet/{processId}/retrigger?processStepTypeId=RETRIGGER_CHECK_OPERATION | | ||
| GET_COMPANY | RETRIGGER_GET_COMPANY | api/dim/process/wallet/{processId}/retrigger?processStepTypeId=RETRIGGER_GET_COMPANY | | ||
| GET_DID_DOCUMENT | RETRIGGER_GET_DID_DOCUMENT | api/dim/process/wallet/{processId}/retrigger?processStepTypeId=RETRIGGER_GET_DID_DOCUMENT | | ||
| CREATE_STATUS_LIST | RETRIGGER_CREATE_STATUS_LIST | api/dim/process/wallet/{processId}/retrigger?processStepTypeId=RETRIGGER_CREATE_STATUS_LIST | | ||
| SEND_CALLBACK | RETRIGGER_SEND_CALLBACK | api/dim/process/wallet/{processId}/retrigger?processStepTypeId=RETRIGGER_SEND_CALLBACK | | ||
|
||
## NOTICE | ||
|
||
This work is licensed under the [Apache-2.0](https://www.apache.org/licenses/LICENSE-2.0). | ||
|
||
- SPDX-License-Identifier: Apache-2.0 | ||
- SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company, BMW Group AG and ssi-dim-middle-layer contributors | ||
- Source URL: https://github.com/SAP/ssi-dim-middle-layer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
# Create Technical User Process | ||
|
||
## Summary | ||
|
||
The create technical user process handles the creation of a technical user. The process steps are the following: | ||
|
||
```mermaid | ||
flowchart TD | ||
A(CREATE_TECHNICAL_USER) -->|Success| B(GET_TECHNICAL_USER_DATA) | ||
B -->|Success| C(GET_TECHNICAL_USER_SERVICE_KEY) | ||
C -->|Success| D(SEND_TECHNICAL_USER_CREATION_CALLBACK) | ||
A-->|Error| E(RETRIGGER_CREATE_TECHNICAL_USER) | ||
B-->|Error| F(RETRIGGER_GET_TECHNICAL_USER_DATA) | ||
C-->|Error| G(RETRIGGER_GET_TECHNICAL_USER_SERVICE_KEY) | ||
D-->|Error| H(RETRIGGER_SEND_TECHNICAL_USER_CREATION_CALLBACK) | ||
E--> A | ||
F--> B | ||
G--> C | ||
H--> D | ||
``` | ||
|
||
## External dependencies | ||
|
||
The process worker communicates with the SAP Dim to create the technical user. It further more communicates with the portal backend to return the technical user data. | ||
|
||
## Process Steps | ||
|
||
### CREATE_TECHNICAL_USER | ||
|
||
The process step `CREATE_TECHNICAL_USER` is automatically triggered from the process worker. It sends a request to create the technical user to the SAP Dim. | ||
|
||
### GET_TECHNICAL_USER_DATA | ||
|
||
The process step `GET_TECHNICAL_USER_DATA` is automatically triggered from the process worker. It requests the status of the operation which is created in the `CREATE_TECHNICAL_USER` step. If the status is `completed` it takes the data of the technical user and saves it in the database. | ||
|
||
### GET_TECHNICAL_USER_SERVICE_KEY | ||
|
||
The process step `GET_TECHNICAL_USER_SERVICE_KEY` is automatically triggered from the process worker. It retrieves the service key id which is the unique identifier of the technical user in the SAP Dim. | ||
|
||
### SEND_TECHNICAL_USER_CREATION_CALLBACK | ||
|
||
The process step `SEND_TECHNICAL_USER_CREATION_CALLBACK` is automatically triggered from the process worker. It sends the technical user details to the portal backend. | ||
|
||
## Retrigger | ||
|
||
| Step Name | Retrigger Step | Retrigger Endpoint | | ||
| ------------------------------------- | ----------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- | | ||
| CREATE_TECHNICAL_USER | RETRIGGER_CREATE_TECHNICAL_USER | api/dim/process/technicalUser/{processId}/retrigger?processStepTypeId=RETRIGGER_CREATE_TECHNICAL_USER | | ||
| GET_TECHNICAL_USER_DATA | RETRIGGER_GET_TECHNICAL_USER_DATA | api/dim/process/technicalUser/{processId}/retrigger?processStepTypeId=RETRIGGER_GET_TECHNICAL_USER_DATA | | ||
| GET_TECHNICAL_USER_SERVICE_KEY | RETRIGGER_GET_TECHNICAL_USER_SERVICE_KEY | api/dim/process/technicalUser/{processId}/retrigger?processStepTypeId=RETRIGGER_GET_TECHNICAL_USER_SERVICE_KEY | | ||
| SEND_TECHNICAL_USER_CREATION_CALLBACK | RETRIGGER_SEND_TECHNICAL_USER_CREATION_CALLBACK | api/dim/process/technicalUser/{processId}/retrigger?processStepTypeId=RETRIGGER_SEND_TECHNICAL_USER_CREATION_CALLBACK | | ||
|
||
## NOTICE | ||
|
||
This work is licensed under the [Apache-2.0](https://www.apache.org/licenses/LICENSE-2.0). | ||
|
||
- SPDX-License-Identifier: Apache-2.0 | ||
- SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company, BMW Group AG and ssi-dim-middle-layer contributors | ||
- Source URL: https://github.com/SAP/ssi-dim-middle-layer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Delete Technical User Process | ||
|
||
## Summary | ||
|
||
The delete technical user process handles the deletion of an technical user. The process steps are the following: | ||
|
||
```mermaid | ||
flowchart TD | ||
A(DELETE_TECHNICAL_USER) -->|Success| B(SEND_TECHNICAL_USER_DELETION_CALLBACK) | ||
A-->|Error| C(RETRIGGER_DELETE_TECHNICAL_USER) | ||
B-->|Error| D(RETRIGGER_SEND_TECHNICAL_USER_DELETION_CALLBACK) | ||
C--> A | ||
D--> B | ||
``` | ||
|
||
## External dependencies | ||
|
||
The process worker communicates with the SAP Dim to delete the technical user. It further more communicates with the portal backend to return the status of the deletion. | ||
|
||
## Process Steps | ||
|
||
### DELETE_TECHNICAL_USER | ||
|
||
The process step `DELETE_TECHNICAL_USER` is automatically triggered from the process worker. It sends a request to delete the technical user from the SAP Dim. | ||
|
||
### SEND_TECHNICAL_USER_DELETION_CALLBACK | ||
|
||
The process step `SEND_TECHNICAL_USER_DELETION_CALLBACK` is automatically triggered from the process worker. It deletes the technical user from the dim database and sends a status update to the portal backend. | ||
|
||
## Retrigger | ||
|
||
| Step Name | Retrigger Step | Retrigger Endpoint | | ||
| ------------------------------------- | ----------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- | | ||
| DELETE_TECHNICAL_USER | RETRIGGER_DELETE_TECHNICAL_USER | api/dim/process/technicalUser/{processId}/retrigger?processStepTypeId=RETRIGGER_DELETE_TECHNICAL_USER | | ||
| SEND_TECHNICAL_USER_DELETION_CALLBACK | RETRIGGER_SEND_TECHNICAL_USER_DELETION_CALLBACK | api/dim/process/technicalUser/{processId}/retrigger?processStepTypeId=RETRIGGER_SEND_TECHNICAL_USER_DELETION_CALLBACK | | ||
|
||
## NOTICE | ||
|
||
This work is licensed under the [Apache-2.0](https://www.apache.org/licenses/LICENSE-2.0). | ||
|
||
- SPDX-License-Identifier: Apache-2.0 | ||
- SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company, BMW Group AG and ssi-dim-middle-layer contributors | ||
- Source URL: https://github.com/SAP/ssi-dim-middle-layer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Summary | ||
|
||
The main process worker project is the `Processes.Worker` which runs all the processes. It therefor looks up `process_steps` in status `TODO` and their respective `processes` and executes those. | ||
|
||
## Processes | ||
|
||
The process worker supports the following processes: | ||
|
||
- [CreateWallet](../processes/01.%20create_wallet.md) - handles the creation of wallets | ||
- [CreateTechnicalUser](../processes/02.%20create_technical_user.md) - handles the creation of technical user | ||
- [DeleteTechnicalUser](../processes/03.%20delete_technical_user.md) - handles the deletion of technical user | ||
|
||
## Retriggering | ||
|
||
The process has a logic to retrigger failing steps. For this a retrigger step is created which can be triggered via an api call to retrigger the step. This logic is implemented separately for each process. In general the retriggering of a step is possible if for example external services are not available. The retrigger logic for each process can be found in the process file. | ||
|
||
## NOTICE | ||
|
||
This work is licensed under the [Apache-2.0](https://www.apache.org/licenses/LICENSE-2.0). | ||
|
||
- SPDX-License-Identifier: Apache-2.0 | ||
- SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company, BMW Group AG and ssi-dim-middle-layer contributors | ||
- Source URL: https://github.com/SAP/ssi-dim-middle-layer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters