[
https://issues.apache.org/jira/browse/HADOOP-15229?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16697907#comment-16697907
]
Steve Loughran commented on HADOOP-15229:
-----------------------------------------
Patch 004 HADOOP-15229 + HADOOP-15364: checkstyles, test failures
* fix checkstyle
* ignore spurious findbugs warning
* fix failing har test (marking more methods as not needing implementation)
* fix ITestS3Select failure where the the name s3a:select.sql hadn't propagated
to the (deliberately) copy & pasted string
* change test in AbstractContractOpenTest to async stream through the file body
and assert about the #of chars read.
TODO: rename csv options input.csv so that if CSV output became tunable & json
support added, there'd be no confusion
h2. Testing
* hadoop-aws: S3 ireland; full suite, s3guard + ddb. Failure in
{{ITestS3AMiniYarnCluster.setup}} w.r.t bouncycastle CP; patch for that pending
elsewhere.
* hadoop-azure : abfs: amsterdam. -for the new open tests
The new {{AbstractContractOpenTest}} test cases now have a better example of
chained async ops
{code}
int len = 4096;
createFile(fs, path, true,
dataset(len, 0x40, 0x80));
CompletableFuture<Long> readAllBytes = fs.openFile(path)
.build()
.thenApply(ContractTestUtils::readStream);
assertEquals("Wrong number of bytes read value",
len,
(long) readAllBytes.get());
{code}
Where {{ContractTestUtils.readStream(InputStream)}} scans the entire stream,
returns a count of # of bytes read, and converts IOEs to AssertionErrors.
> Add FileSystem builder-based openFile() API to match createFile()
> -----------------------------------------------------------------
>
> Key: HADOOP-15229
> URL: https://issues.apache.org/jira/browse/HADOOP-15229
> Project: Hadoop Common
> Issue Type: New Feature
> Components: fs, fs/azure, fs/s3
> Affects Versions: 3.0.0
> Reporter: Steve Loughran
> Assignee: Steve Loughran
> Priority: Major
> Attachments: HADOOP-15229-001.patch, HADOOP-15229-002.patch,
> HADOOP-15229-003.patch, HADOOP-15229-004.patch, HADOOP-15229-004.patch
>
>
> Replicate HDFS-1170 and HADOOP-14365 with an API to open files.
> A key requirement of this is not HDFS, it's to put in the fadvise policy for
> working with object stores, where getting the decision to do a full GET and
> TCP abort on seek vs smaller GETs is fundamentally different: the wrong
> option can cost you minutes. S3A and Azure both have adaptive policies now
> (first backward seek), but they still don't do it that well.
> Columnar formats (ORC, Parquet) should be able to say "fs.input.fadvise"
> "random" as an option when they open files; I can imagine other options too.
> The Builder model of [~eddyxu] is the one to mimic, method for method.
> Ideally with as much code reuse as possible
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]