Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HADOOP-19256. steve's pr of conditional writes #7362

Draft
wants to merge 14 commits into
base: trunk
Choose a base branch
from

Conversation

steveloughran
Copy link
Contributor

#7329 with some changes

@steveloughran steveloughran marked this pull request as draft February 6, 2025 12:17
@steveloughran steveloughran force-pushed the s3/HADOOP-19256-s3-conditional-writes branch from 82aa6e1 to d04aa2e Compare February 6, 2025 20:14
steveloughran and others added 2 commits February 7, 2025 10:00
+ hadoop common and s3a create file options

wired up to s3a create file builder, and nowhere else.

Change-Id: Ieaafa9ecdfd68306deb41ecf40c416374a310859
@steveloughran
Copy link
Contributor Author

Tested: S3 london, -Dparallel-tests -DtestsThreadCount=9
One failure due to SDK update not telling us off any more.



[ERROR] Tests run: 2, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 6.152 s <<< FAILURE! - in org.apache.hadoop.fs.s3a.impl.ITestAwsSdkWorkarounds
[ERROR] testNoisyLogging(org.apache.hadoop.fs.s3a.impl.ITestAwsSdkWorkarounds)  Time elapsed: 2.318 s  <<< FAILURE!
java.lang.AssertionError: 
[LOG output does not contain the forbidden text. Has the SDK been fixed?] 
Expecting:
 <"">
to contain:
 <"The provided S3AsyncClient is an instance of MultipartS3AsyncClient"> 
        at org.apache.hadoop.fs.s3a.impl.ITestAwsSdkWorkarounds.testNoisyLogging(ITestAwsSdkWorkarounds.java:100)
 

+ test timeout of ITestS3APrefetchingLruEviction.testSeeksWithLruEviction

@steveloughran
Copy link
Contributor Author

@saikatroy038 the two commits here are ready to be cherrypicked.

@steveloughran steveloughran force-pushed the s3/HADOOP-19256-s3-conditional-writes branch from e39ecb3 to 40a5839 Compare February 10, 2025 15:31
…art files

createFile() options are passed down all the way to object creation
* fs.option.create.conditional.overwrite: sets the header.
  MUST be in close(). After all, create(overwrite=false) is eager.
* fs.option.create.conditional.overwrite.etag requests etag writes.
  MAY be in create(); may be in close().
* fs.option.create.content.type for mime type.
* fs.option.create.in.close to ask for create in close, as fs capability.
  (maybe make this an fs path capability only?)
* fs.s3a.create.multipart : allows tests to create small multipart files

Javadocs of the fs.option.create try to define semantics; will need
strict fs specification soon.

Bool params come down in an enumset of flags; I'm going to do that in
more code as it is more flexible over time than many booleans.

- etag values are passed down but not wired up/tested
- content type flag exists but is ignored

New WriteObjectFlags enum is in new package o.a.h.fs.s3a.write;
to match the streams package in another ongoing PR.
Goal, as we maintain things, all code related to writing can
go in here.

also: options set by WriteObjectFlags return true in hasCapability()
of the stream

Change-Id: I301abd7397accbd278d05f42f858223ba1349fc8
@steveloughran steveloughran force-pushed the s3/HADOOP-19256-s3-conditional-writes branch from 40a5839 to 63c30eb Compare February 10, 2025 17:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant