ruanwenjun commented on code in PR #12486:
URL:
https://github.com/apache/dolphinscheduler/pull/12486#discussion_r1002498672
##########
dolphinscheduler-worker/src/main/java/org/apache/dolphinscheduler/server/worker/utils/TaskExecutionCheckerUtils.java:
##########
@@ -131,4 +138,23 @@ public static void
downloadResourcesIfNeeded(StorageOperate storageOperate,
}
}
}
+
+ private static void createDirectoryWithOwner(Path filePath, String tenant)
{
+ if (Files.exists(filePath)) {
+ return;
+ }
+ try {
+ Files.createDirectories(filePath);
+ if (!OSUtils.isSudoEnable()) {
+ // we need to open sudo, then we can change the owner.
+ return;
Review Comment:
If we throw an exception here, it means we only support deploy with `sudo`,
then this switch is meaningless. We don't need to throw exception here.
--
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]