You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zeppelin.apache.org by GitBox <gi...@apache.org> on 2021/04/20 15:57:01 UTC

[GitHub] [zeppelin] cuspymd commented on a change in pull request #4097: [ZEPPELIN-5330]. Support conda env for python interpreter in yarn mode

cuspymd commented on a change in pull request #4097:
URL: https://github.com/apache/zeppelin/pull/4097#discussion_r616816582



##########
File path: zeppelin-plugins/launcher/yarn/src/main/java/org/apache/zeppelin/interpreter/launcher/YarnRemoteInterpreterProcess.java
##########
@@ -242,13 +244,15 @@ private ContainerLaunchContext setUpAMLaunchContext() throws IOException {
 
     // Set the resources to localize
     this.stagingDir = new Path(fs.getHomeDirectory() + "/.zeppelinStaging", appId.toString());
+    LOGGER.info("Use staging directory: {}", this.stagingDir);
     Map<String, LocalResource> localResources = new HashMap<>();
 
     File interpreterZip = createInterpreterZip();
     Path srcPath = localFs.makeQualified(new Path(interpreterZip.toURI()));
     Path destPath = copyFileToRemote(stagingDir, srcPath, (short) 1);
     addResource(fs, destPath, localResources, LocalResourceType.ARCHIVE, "zeppelin");
-    FileUtils.forceDelete(interpreterZip);
+    LOGGER.info("Add zeppelin archive: {}", destPath);
+    //FileUtils.forceDelete(interpreterZip);

Review comment:
       Does it mean that commenting without erasing is a temporary modification?

##########
File path: zeppelin-plugins/launcher/yarn/src/main/java/org/apache/zeppelin/interpreter/launcher/YarnRemoteInterpreterProcess.java
##########
@@ -266,6 +270,30 @@ private ContainerLaunchContext setUpAMLaunchContext() throws IOException {
         addResource(fs, destPath, localResources, LocalResourceType.ARCHIVE, "hive_conf");
       }
     }
+
+    String yarnDistArchives = launchContext.getProperties().getProperty("zeppelin.yarn.dist.archives");
+    if (org.apache.commons.lang3.StringUtils.isNotBlank(yarnDistArchives)) {

Review comment:
       In the file, `org.apache.commons.lang3.StringUtils` is used 7 times, and `org.apache.hadoop.util.StringUtils` is used 1 time. I think it would be okay to use `org.apache.commons.lang3.StringUtils` in short form.

##########
File path: zeppelin-plugins/launcher/yarn/src/main/java/org/apache/zeppelin/interpreter/launcher/YarnRemoteInterpreterProcess.java
##########
@@ -316,6 +344,25 @@ private ContainerLaunchContext setUpAMLaunchContext() throws IOException {
     return amContainer;
   }
 
+  public URI resolveURI(String path) {

Review comment:
       public?




-- 
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:
users@infra.apache.org