BruceWong96 commented on code in PR #16923:
URL:
https://github.com/apache/dolphinscheduler/pull/16923#discussion_r1897203084
##########
dolphinscheduler-common/src/main/java/org/apache/dolphinscheduler/common/utils/FileUtils.java:
##########
@@ -272,6 +271,12 @@ public static void createDirectoryWith755(@NonNull Path
path) throws IOException
}
}
+ public static Path setOwner(@NonNull Path path, @NonNull String owner)
throws IOException {
+ UserPrincipalLookupService lookupService =
FileSystems.getDefault().getUserPrincipalLookupService();
+ UserPrincipal user = lookupService.lookupPrincipalByName(owner);
+ return Files.setOwner(path, user);
Review Comment:
OK
--
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]