feat: Add shared-bucket multitenancy support for OSS attachments#767
feat: Add shared-bucket multitenancy support for OSS attachments#767Schmarvinius wants to merge 6 commits intomainfrom
Conversation
SummaryThe following content is AI-generated and provides a summary of the pull request: Add Shared-Bucket Multitenancy Support for OSS AttachmentsNew Features✨ Introduces shared-bucket multitenancy support for the OSS attachments feature across AWS S3, Azure Blob Storage, and Google Cloud Storage. In shared mode, object keys are prefixed with Key additions:
Changes
PR Bot InformationVersion:
💌 Have ideas or want to contribute? Create an issue and share your thoughts with us! Made with ❤️ by Hyperspace. |
There was a problem hiding this comment.
The PR introduces solid multi-tenancy support with good test coverage, but has several correctness issues that need addressing: a null tenant ID in TenantCleanupHandler that silently mutates into a "null/" prefix, a swallowed InterruptedException in the Azure client's parallel delete loop, partial S3 deletion failures that are logged but treated as success, a dead-code/confusing fallback in getTenant, and a leaked ExecutorService with no shutdown lifecycle in Registration.
PR Bot Information
Version: 1.19.3 | 📖 Documentation | 🚨 Create Incident | 💬 Feedback
- LLM:
anthropic--claude-4.6-sonnet - Event Trigger:
pull_request.opened - Correlation ID:
f7afc630-2b61-11f1-9530-36fd128ef1d9
.../src/main/java/com/sap/cds/feature/attachments/oss/handler/OSSAttachmentsServiceHandler.java
Show resolved
Hide resolved
...re-attachments-oss/src/main/java/com/sap/cds/feature/attachments/oss/client/AzureClient.java
Show resolved
Hide resolved
...ture-attachments-oss/src/main/java/com/sap/cds/feature/attachments/oss/client/AWSClient.java
Show resolved
Hide resolved
...ents-oss/src/main/java/com/sap/cds/feature/attachments/oss/handler/TenantCleanupHandler.java
Show resolved
Hide resolved
...hments-oss/src/main/java/com/sap/cds/feature/attachments/oss/configuration/Registration.java
Show resolved
Hide resolved
|
Tested locally and it looks good |
|
Next up:
|
Description:
Summary
{tenantId}/{contentId}) for shared-bucket mode across AWS, Azure, and GCPdeleteContentByPrefixon all OSClient implementations for tenant cleanup on unsubscribeversions(true))Test plan
MultiTenantIsolationTest(tenant isolation, path traversal, null tenant)TenantCleanupHandlerandRegistrationtests for wiring