Repository navigation
feat: Handle MRAP URI #19609
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
amaechler
merged 8 commits into
apache:master
from
deep-bi:deep/feature/Add-AWS-MRAP-support
Nov 17, 2026
Merged
feat: Handle MRAP URI #19609
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
f7d4ebc
Handle MRAP URI
vivek807 e06de77
Address review comment
vivek807 f017b79
Moved ARN rules out of CloudObjectLocation into a CloudBucketValidato…
vivek807 96d9afe
Merge upstream/master into deep/feature/Add-AWS-MRAP-support
vivek807 4daf3f0
Route regional access point ARNs to their own Region
vivek807 b5391ac
fix: address MRAP review feedback
vivek807 eda40a6
fix: delete MRAP objects one key at a time
vivek807 ccf9c46
Merge upstream/master into deep/feature/Add-AWS-MRAP-support
vivek807 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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
52 changes: 52 additions & 0 deletions
52
...sions-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/S3BucketValidator.java
This file contains hidden or 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,52 @@ | ||
| /* | ||
| * Licensed to the Apache Software Foundation (ASF) under one | ||
| * or more contributor license agreements. See the NOTICE file | ||
| * distributed with this work for additional information | ||
| * regarding copyright ownership. The ASF licenses this file | ||
| * to you under the Apache License, Version 2.0 (the | ||
| * "License"); you may not use this file except in compliance | ||
| * with the License. You may obtain a copy of the License at | ||
| * | ||
| * http://www.apache.org/licenses/LICENSE-2.0 | ||
| * | ||
| * Unless required by applicable law or agreed to in writing, | ||
| * software distributed under the License is distributed on an | ||
| * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
| * KIND, either express or implied. See the License for the | ||
| * specific language governing permissions and limitations | ||
| * under the License. | ||
| */ | ||
|
|
||
| package org.apache.druid.storage.s3; | ||
|
|
||
| import org.apache.druid.data.input.impl.CloudBucketValidator; | ||
| import org.apache.druid.java.util.common.IAE; | ||
|
|
||
| /** | ||
| * Accepts plain bucket names and S3 Access Point / Multi-Region Access Point ARNs in colon form. | ||
| * | ||
| * {@link org.apache.druid.data.input.impl.CloudObjectLocation} permits ':' in any bucket, so this rejects colons | ||
| * outside a well-formed ARN. That also catches slash-form ARNs inside a URI, such as | ||
| * s3://arn:aws:s3::<account>:accesspoint/alias.mrap/key, where {@link java.net.URI} truncates the bucket to | ||
| * arn:aws:s3::<account>:accesspoint and moves the access point name into the key. | ||
| */ | ||
| public class S3BucketValidator implements CloudBucketValidator | ||
| { | ||
| public static final S3BucketValidator INSTANCE = new S3BucketValidator(); | ||
|
|
||
| private S3BucketValidator() | ||
| { | ||
| } | ||
|
|
||
| @Override | ||
| public void validate(String bucket) | ||
| { | ||
| if (bucket.indexOf(':') >= 0 && !S3Utils.isS3Arn(bucket)) { | ||
| throw new IAE( | ||
| "Invalid S3 bucket [%s]. Use a bucket name, or an S3 Access Point or Multi-Region Access Point ARN" | ||
| + " in colon form: arn:<partition>:s3:<region>:<account>:accesspoint:<name>", | ||
| bucket | ||
| ); | ||
| } | ||
| } | ||
| } |
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.