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

Gabor Bota edited comment on HADOOP-15827 at 10/8/18 9:32 PM:
--------------------------------------------------------------

Thanks, it makes sense now. I was able to reproduce the issue injecting 
{{dirPathMeta=null}} in readOp while debugging.
The solution will be just to change 
{code:java}
return (metas.isEmpty() && dirPathMeta == null)
{code}
to this 
{code:java}
return (metas.isEmpty() || dirPathMeta == null)
{code}
I'll upload a patch but without a test - it wouldn't be trivial to do the test, 
but I'll try if needed.



was (Author: gabor.bota):
Thanks, it makes sense now. I was able to reproduce the issue injecting 
{{dirPathMeta=null}} in readOp while debugging.
The solution will be just to change 
{code:java}
return (metas.isEmpty() && dirPathMeta == null)
{code}
to this 
{code:java}
return (metas.isEmpty() || dirPathMeta == null)
{code}
I'll upload a patch but without a test - it would be a pain to write 
integration test for this. I hope that's acceptable.


> NPE in DynamoDBMetadataStore.lambda$listChildren for root + auth s3guard
> ------------------------------------------------------------------------
>
>                 Key: HADOOP-15827
>                 URL: https://issues.apache.org/jira/browse/HADOOP-15827
>             Project: Hadoop Common
>          Issue Type: Sub-task
>          Components: fs/s3
>    Affects Versions: 3.3.0
>            Reporter: Steve Loughran
>            Assignee: Gabor Bota
>            Priority: Blocker
>         Attachments: HADOOP-15827.001.patch
>
>
> NPE in a test run of {{-Dparallel-tests -DtestsThreadCount=6  -Ds3guard 
> -Ddynamodb -Dauthoritative}}
> {code}
> [ERROR] testLSRootDir(org.apache.hadoop.fs.s3a.ITestS3AFileSystemContract)  
> Time elapsed: 42.822 s  <<< ERROR!
> java.lang.NullPointerException
> {code}



--
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