EricJoy2048 commented on code in PR #6717:
URL: https://github.com/apache/seatunnel/pull/6717#discussion_r1567024160


##########
seatunnel-connectors-v2/connector-file/connector-file-s3/src/main/java/org/apache/seatunnel/connectors/seatunnel/file/s3/config/S3Conf.java:
##########
@@ -73,13 +77,13 @@ public static HadoopConf buildWithConfig(Config config) {
 
     public static HadoopConf buildWithReadOnlyConfig(ReadonlyConfig 
readonlyConfig) {
         Config config = readonlyConfig.toConfig();
-        HadoopConf hadoopConf = new 
S3Conf(readonlyConfig.get(S3ConfigOptions.S3_BUCKET));
-        String bucketName = readonlyConfig.get(S3ConfigOptions.S3_BUCKET);
+        String bucketName = config.getString(S3ConfigOptions.S3_BUCKET.key());

Review Comment:
   Can reuse the code above:
   
   ```
   return buildWithReadOnlyConfig(readonlyConfig.toConfig);
   
   ```



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

To unsubscribe, e-mail: [email protected]

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

Reply via email to