[
https://issues.apache.org/jira/browse/HADOOP-15625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16785888#comment-16785888
]
Ben Roling commented on HADOOP-15625:
-------------------------------------
{quote}
java.lang.AssertionError: java.net.MalformedURLException: unknown protocol: s3a
{quote}
Looks like S3ATestUtils.getTestBucketName should use URI instead of URL. I'm
attaching a 015 patch that fixes that as well as a few trailing whitespace
issues.
{noformat}
diff HADOOP-15625-014.patch HADOOP-15625-015.patch
1232c1232
< index 11ff6104e7d..e4729071b09 100644
---
> index 11ff6104e7d..35c8416fa3a 100644
1326c1326
< +This means an open input stream will still be able to seek backwards after a
---
> +This means an open input stream will still be able to seek backwards after a
1332c1332
< +have object versioning enabled from the beginning.
---
> +have object versioning enabled from the beginning.
1340c1340
< +may not support all change detection mechanisms.
---
> +may not support all change detection mechanisms.
1368c1368
< index b3c3e38ef03..c4ef5f6e319 100644
---
> index b3c3e38ef03..3123221bd82 100644
1440,1441c1440,1441
< +org.apache.hadoop.fs.s3a.RemoteFileChangedException: re-open
`s3a://my-bucket/test/file.txt':
< + ETag change reported by S3 while reading at position 1949.
---
> +org.apache.hadoop.fs.s3a.RemoteFileChangedException: re-open
> `s3a://my-bucket/test/file.txt':
> + ETag change reported by S3 while reading at position 1949.
1806c1806
< index e15c24aced8..3e7cf02650b 100644
---
> index e15c24aced8..d2635a4ab39 100644
1827c1827
< @@ -695,6 +698,23 @@ public static MarshalledCredentials
requestSessionCredentials(
---
> @@ -695,6 +698,18 @@ public static MarshalledCredentials
> requestSessionCredentials(
1836d1835
< + * @throws AssertionError test fs option is not a URL
1841,1845c1840
< + try {
< + return new URL(bucket).getHost();
< + } catch (MalformedURLException e) {
< + throw new AssertionError(e);
< + }
---
> + return URI.create(bucket).getHost();
{noformat}
> S3A input stream to use etags to detect changed source files
> ------------------------------------------------------------
>
> Key: HADOOP-15625
> URL: https://issues.apache.org/jira/browse/HADOOP-15625
> Project: Hadoop Common
> Issue Type: Sub-task
> Components: fs/s3
> Affects Versions: 3.2.0
> Reporter: Brahma Reddy Battula
> Assignee: Brahma Reddy Battula
> Priority: Major
> Attachments: HADOOP--15625-006.patch, HADOOP-15625-001.patch,
> HADOOP-15625-002.patch, HADOOP-15625-003.patch, HADOOP-15625-004.patch,
> HADOOP-15625-005.patch, HADOOP-15625-006.patch, HADOOP-15625-007.patch,
> HADOOP-15625-008.patch, HADOOP-15625-009.patch, HADOOP-15625-010.patch,
> HADOOP-15625-011.patch, HADOOP-15625-012.patch, HADOOP-15625-013-delta.patch,
> HADOOP-15625-013.patch, HADOOP-15625-014.patch, HADOOP-15625-015.patch
>
>
> S3A input stream doesn't handle changing source files any better than the
> other cloud store connectors. Specifically: it doesn't noticed it has
> changed, caches the length from startup, and whenever a seek triggers a new
> GET, you may get one of: old data, new data, and even perhaps go from new
> data to old data due to eventual consistency.
> We can't do anything to stop this, but we could detect changes by
> # caching the etag of the first HEAD/GET (we don't get that HEAD on open with
> S3Guard, BTW)
> # on future GET requests, verify the etag of the response
> # raise an IOE if the remote file changed during the read.
> It's a more dramatic failure, but it stops changes silently corrupting things.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]