Skip to content

2025/04 API and DTO sync #2357

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 14 commits into from
May 8, 2025
Merged

2025/04 API and DTO sync #2357

merged 14 commits into from
May 8, 2025

Conversation

afranken
Copy link
Member

Description

  • API / DTO consistency check 2025/04
    • Check AWS API for changes
    • Update S3Mock API / DTOs
    • Add tests for changed API / DTOs

Related Issue

Fixes #2340

Tasks

  • I have signed the CLA.
  • I have written tests and verified that they fail without my change.

@afranken afranken self-assigned this Apr 27, 2025
@afranken afranken force-pushed the 2340-2025-04-api-and-dto-sync branch 9 times, most recently from ca3cb77 to 4ab61cb Compare May 7, 2025 17:18
@afranken afranken force-pushed the 2340-2025-04-api-and-dto-sync branch from 4ab61cb to 64b84cd Compare May 8, 2025 00:21
@afranken afranken requested a review from Copilot May 8, 2025 00:21
Copilot

This comment was marked as outdated.

@afranken afranken force-pushed the 2340-2025-04-api-and-dto-sync branch 2 times, most recently from c894064 to ec0dc21 Compare May 8, 2025 15:33
@afranken afranken requested a review from Copilot May 8, 2025 19:57
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR brings API and DTO synchronizations to align S3Mock with updated AWS S3 APIs for 2025. Key changes include updating copyright notices to 2025, adding new header converters and beans (e.g. ChecksumModeHeaderConverter and RegionConverter), and extensive modifications to endpoint signatures and integration tests to support new checksum and conditional request functionalities.

Reviewed Changes

Copilot reviewed 155 out of 155 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
S3MockProperties.java Updated copyright year and switched to using the local dto.Region.
S3MockConfiguration.java Added new beans for ChecksumMode and Region conversion.
S3Exception.java Updated error message wording for INVALID_PART and added a new static method for missing checksum errors.
ObjectController.java Annotated endpoints with @S3Verified and updated header handling (including checksum and conditional request parameters).
MultipartController.java, BucketController.java Updated parameter naming and added conditional request support; improved test annotations.
Integration Tests (Kotlin) Refactored test method names and assertions to reflect new API behaviors.
pom.xml, CHANGELOG.md Updated dependency versions and changelog to document API/DTO consistency changes.
Comments suppressed due to low confidence (2)

server/src/main/java/com/adobe/testing/s3mock/ObjectController.java:437

  • Consider whether relying solely on 'if (mode == ChecksumMode.ENABLED)' is sufficient. If other valid checksum modes exist or if different behaviors are needed when disabled, document or adjust the handling accordingly.
.headers(h -> { if (mode == ChecksumMode.ENABLED) { h.setAll(checksumHeaderFrom(s3ObjectMetadata)); } })

integration-tests/src/test/kotlin/com/adobe/testing/s3mock/its/MultipartIT.kt:60

  • The test class was renamed from 'MultiPartIT' to 'MultipartIT'; please ensure that all references and documentation reflect this consistent naming convention.
internal class MultipartIT : S3TestBase() {

afranken added 10 commits May 8, 2025 22:36
TestContainers refuses to update to a non-vulnerable version.
See testcontainers/testcontainers-java#8338
This is so we can track when a function or DTO was validated against
S3 APIs and is up-to-date.
Checking AWS APIs for changes and S3Mock for implementations and tests.

Fixes #2340
Checking AWS APIs for changes and S3Mock for implementations and tests.

Fixes #2340
Checking AWS APIs for changes and S3Mock for implementations and tests.

Fixes #2340
Test ITs against S3 again to see if there are differences in
behaviour, fix S3Mock if necessary.

# Conflicts:
#	integration-tests/src/test/kotlin/com/adobe/testing/s3mock/its/BucketIT.kt
afranken added 4 commits May 8, 2025 22:36
Checking AWS APIs for changes and S3Mock for implementations and tests.

Fixes #2340
Checking AWS APIs for changes and S3Mock for implementations and tests.

Fixes #2340
Fixes #2371
@afranken afranken force-pushed the 2340-2025-04-api-and-dto-sync branch from 1355d5e to b084188 Compare May 8, 2025 20:37
@afranken afranken merged commit ae2cf60 into main May 8, 2025
6 checks passed
@afranken afranken deleted the 2340-2025-04-api-and-dto-sync branch May 8, 2025 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2025-04 sync of API and DTOs
1 participant