eclipse-edc / eclipse-edc/Technology-Aws

Refactor S3 provisioners

Open
#539 3 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
8
Forks
19
PR merge metrics
No merged PRs in 30d

Description

# Feature Request

The S3 provisioners create and utilize pipelines for chaining multiple AWS requests as part of the (de)provisioning processes. This makes the `*Provisioner` classes quite clean, but the pipeline classes become rather unreadable and hard to test, the more operations are chained. They should therefore be refactored.

One idea to achieve this, would be to create wrapper clients for the actual AWS SDK clients, which can offer higher-level features by performing multiple requests that are part of the same operation within one method call. E.g. deleting a role requires 2 requests (`deleteRolePolicy` and `deleteRole`), even though it could be considered one operation. This would reduce the number of calls made within the provisioners. Additionally, retry logic and error handling could be integrated into these wrapper clients, leaving only a few concise method calls to be performed by the provisioners.

## Which Areas Would Be Affected?

provisioners

## Why Is the Feature Desired?

cleaner code, testability

## Who will sponsor this feature?

me

## Solution Proposal

- Create wrapper clients as described above
- Use wrapper clients in the provisioners
- Remove (de)provisioning pipelines

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.