[
https://issues.apache.org/jira/browse/HADOOP-14759?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16412235#comment-16412235
]
Aaron Fabbri commented on HADOOP-14759:
---------------------------------------
Thanks for the patch [~gabor.bota]. Looks pretty good. A couple of comments:
{noformat}
@Override
- @Retries.OnceRaw("once(batchWrite)")
public void prune(long modTime) throws IOException {
{noformat}
Looks like an accidental deletion of the annotation, should probably add it
back.
{noformat}
+ // remove the protocol from path string to get parent
+ // should keep one starting slash
+ String keyPrefix = paths.get(0).replaceFirst("s3a:/", "");
{noformat}
You can probably use PathMetadataDynamoDBTranslation#pathToParentKey() here
instead.
Also, do we need to update any of the docs in
hadoop-tools/hadoop-aws/src/site/markdown/tools/hadoop-aws?
{quote}
Tests ran on us-west-2 successfully.
{quote}
Thank you for declaring where you ran tests. This included both unit (mvn
test) and integration tests (mvn verify), right?
> S3GuardTool prune to prune specific bucket entries
> --------------------------------------------------
>
> Key: HADOOP-14759
> URL: https://issues.apache.org/jira/browse/HADOOP-14759
> Project: Hadoop Common
> Issue Type: Sub-task
> Components: fs/s3
> Affects Versions: 3.0.0-beta1
> Reporter: Steve Loughran
> Assignee: Gabor Bota
> Priority: Minor
> Attachments: HADOOP-14759.001.patch, HADOOP-14759.002.patch
>
>
> Users may think that when you provide a URI to a bucket, you are pruning all
> entries in the table *for that bucket*. In fact you are purging all entries
> across all buckets in the table:
> {code}
> hadoop s3guard prune -days 7 s3a://ireland-1
> {code}
> It should be restricted to that bucket, unless you specify otherwise
> +maybe also add a hard date rather than a relative one
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]