Skip to content

Comments

HDDS-14685. Create context for BucketOperationHandler#9798

Merged
adoroszlai merged 3 commits intoapache:masterfrom
adoroszlai:HDDS-14685
Feb 22, 2026
Merged

HDDS-14685. Create context for BucketOperationHandler#9798
adoroszlai merged 3 commits intoapache:masterfrom
adoroszlai:HDDS-14685

Conversation

@adoroszlai
Copy link
Contributor

What changes were proposed in this pull request?

Minor refactoring around BucketOperationHandler based on more recent implementation of ObjectOperationHandler.

  • Extract S3RequestContext as parent class of ObjectRequestContext.
  • Create instance of S3RequestContext and pass it to BucketOperationHandler.
  • Refactor BucketOperationHandler to be an abstract class to reduce duplication.

https://issues.apache.org/jira/browse/HDDS-14685

How was this patch tested?

CI:
https://github.com/adoroszlai/ozone/actions/runs/22226388402

@adoroszlai adoroszlai self-assigned this Feb 20, 2026
@adoroszlai adoroszlai added the s3 S3 Gateway label Feb 20, 2026
Copy link

@yandrey321 yandrey321 left a comment

Choose a reason for hiding this comment

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

lgtm

Copy link
Contributor

@ivandika3 ivandika3 left a comment

Choose a reason for hiding this comment

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

Thanks @adoroszlai , overall LGTM +1. Left some nits which can be addressed in follow-ups.

I am wondering whether this chain of responsibility pattern can be easily reused when we want to reimplement S3G in Netty (HDDS-9820) in the future. For example, I can somewhat see similarities between Netty ChannelPipeline and ChannelHandler and the current chain of responsibility pattern.

Comment on lines 80 to 82
if (!shouldHandle()) {
return null; // Not responsible for this request
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Technically, the shouldHandle can be refactored out, since it is part of the chain of responsibility framework instead of the S3 handler implementation. This can be addressed in follow-ups.

@adoroszlai adoroszlai merged commit 021042e into apache:master Feb 22, 2026
44 checks passed
@adoroszlai adoroszlai deleted the HDDS-14685 branch February 22, 2026 08:11
@adoroszlai
Copy link
Contributor Author

Thanks @ivandika3, @yandrey321 for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

s3 S3 Gateway

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants