[ 
https://issues.apache.org/jira/browse/HADOOP-15843?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16742115#comment-16742115
 ] 

Adam Antal commented on HADOOP-15843:
-------------------------------------

Please correct me if I'm wrong, but I suggest not to modify 
{{initMetadataStore}}, as for the case when neither the filesystem nor the 
metadatastore is provided, for Init and Destroy S3GuardTools 
{{checkBucketNameOrDDBTableNameProvided(paths)}} is called which does this 
exact check. As for the other tools, different kind of {{invalidArgs}} are 
thrown, if there's no bucket specified.

What do you think about it [[email protected]]? I'm about to have a patch for 
it, but if I'm on a wrong path, I just discard it and stick to your original 
thoughts.

The other parts of the patch are fine, only I modified the test.

> s3guard bucket-info command to not print a stack trace on bucket-not-found
> --------------------------------------------------------------------------
>
>                 Key: HADOOP-15843
>                 URL: https://issues.apache.org/jira/browse/HADOOP-15843
>             Project: Hadoop Common
>          Issue Type: Sub-task
>          Components: fs/s3
>    Affects Versions: 3.3.0
>            Reporter: Steve Loughran
>            Assignee: Adam Antal
>            Priority: Minor
>         Attachments: HADOOP-15843-001.patch
>
>
> when you go {{hadoop s3guard bucket-info s3a://bucket-which-doesnt-exist}} 
> you get a full stack trace on the failure. This is overkill: all the caller 
> needs to know is the bucket isn't there.
> Proposed: catch FNFE and treat as special, have return code of "44", "not 
> found".



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to