jackye1995 opened a new pull request #1900:
URL: https://github.com/apache/iceberg/pull/1900


   @danielcweeks made the following updates to `S3FileIO` related code:
   1. added integration tests that verifies upload behaviors against S3
   2. updated variable names and documentations in `AwsProperties` to be 
consistent with others, added corresponding tests
   3. fixed invalid reference to private variable `S3URI#VALID_SCHEMES` in doc 
of `S3FileIO`
   4. muted errorprone warnings:
   
   ```
   /iceberg/aws/src/main/java/org/apache/iceberg/aws/s3/S3RequestUtil.java:35: 
warning: [UnnecessaryLambda] Returning a lambda from a helper method or saving 
it in a constant is unnecessary; prefer to implement the functional interface 
method directly and use a method reference instead.
     private static final Function<ServerSideEncryption, S3Request.Builder> 
NULL_SSE_SETTER = sse -> null;
                                                                            ^
       (see https://errorprone.info/bugpattern/UnnecessaryLambda)
     Did you mean 'private static  S3Request.Builder 
nullSseSetter(ServerSideEncryption sse){return null;}'?
   /iceberg/aws/src/main/java/org/apache/iceberg/aws/s3/S3RequestUtil.java:36: 
warning: [UnnecessaryLambda] Returning a lambda from a helper method or saving 
it in a constant is unnecessary; prefer to implement the functional interface 
method directly and use a method reference instead.
     private static final Function<String, S3Request.Builder> 
NULL_STRING_SETTER = s -> null;
                                                              ^
       (see https://errorprone.info/bugpattern/UnnecessaryLambda)
     Did you mean 'private static  S3Request.Builder nullStringSetter(String 
s){return null;}'?
   /iceberg/aws/src/main/java/org/apache/iceberg/aws/s3/S3OutputStream.java:92: 
warning: [StaticAssignmentInConstructor] This assignment is to a static field. 
Mutating static state from a constructor is highly error-prone.
             executorService = MoreExecutors.getExitingExecutorService(
                             ^
       (see https://errorprone.info/bugpattern/StaticAssignmentInConstructor)
   /iceberg/aws/src/main/java/org/apache/iceberg/aws/s3/S3OutputStream.java:92: 
warning: [StaticGuardedByInstance] Write to static variable should not be 
guarded by instance lock 'this'
             executorService = MoreExecutors.getExitingExecutorService(
             ^
       (see https://errorprone.info/bugpattern/StaticGuardedByInstance)
   4 warnings
   ```


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



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

Reply via email to