You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2022/09/22 09:50:33 UTC

[GitHub] [dolphinscheduler] duhanmin opened a new pull request, #12106: Datax can submit to YARN

duhanmin opened a new pull request, #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106

   Instructions:
   
   Configure the environment variables DATAX_ON_YARN_DEPEND_JAR and DATAX_HDFS_PATH to run DATAX ON YARN
   
   Parameter explanation:
   DATAX_ON_YARN_DEPEND_JAR:
   https://github.com/duhanmin/datax-on-yarn Compile and package
   
   DATAX_HDFS_PATH:
   You need to upload the datax installation package to yarn
   
   
   example:
   ````
   #export DATAX_ON_YARN_DEPEND_JAR=${DATAX_ON_YARN_DEPEND_JAR:-/opt/soft/datax/datax-on-yarn-1.0.0.jar}
   #DATAX_HDFS_HOME is HDFS path
   #export DATAX_HDFS_PATH=${DATAX_HDFS_HOME:-/hdfs/opt/hadoop/datax.tar.gz}
   ````


-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on pull request #12106: Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
duhanmin commented on PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#issuecomment-1254790786

   使用方法:
   
   配置环境变量DATAX_ON_YARN_DEPEND_JAR和DATAX_HDFS_PATH就可以运行DATAX ON YARN
   
   参数解释:
   DATAX_ON_YARN_DEPEND_JAR:
   https://github.com/duhanmin/datax-on-yarn 编译打包
   
   DATAX_HDFS_PATH:
   需要将datax安装包上传到yarn
   
   
   例子:
   ```
   #export DATAX_ON_YARN_DEPEND_JAR=${DATAX_ON_YARN_DEPEND_JAR:-/opt/soft/datax/datax-on-yarn-1.0.0.jar}
   #DATAX_HDFS_HOME is HDFS path
   #export DATAX_HDFS_PATH=${DATAX_HDFS_HOME:-/hdfs/opt/hadoop/datax.tar.gz}
   ```


-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] EricGao888 commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
EricGao888 commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r979266781


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -419,6 +438,58 @@ private String buildShellCommandFile(String jobConfigFilePath, Map<String, Prope
         return fileName;
     }
 
+    private String buildYarnShellCommandFile(String jobConfigFilePath, Map<String, Property> paramsMap, String dataxHdfsPath, String dataxOnYarnDependJar)

Review Comment:
   Since the execution of many DS task plugins is based on `ShellExecutor`, would u like to improve it so that those tasks could also run shell command in yarn containers? BTW, in this PR, it seems `datax-on-yarn-1.0.0.jar` is built from code in an individual repo and this might not be a good practice. https://github.com/apache/dolphinscheduler/blob/dev/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/ShellCommandExecutor.java



##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -94,6 +94,17 @@ public class DataxTask extends AbstractTaskExecutor {
      * datax path
      */
     private static final String DATAX_PATH = "${DATAX_HOME}/bin/datax.py";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_HDFS_PATH = "DATAX_HDFS_PATH";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_ON_YARN_DEPEND_JAR = "DATAX_ON_YARN_DEPEND_JAR";

Review Comment:
   May I ask whether we have an option for users to choose to submit a `DataX` task to yarn or not in UI? 



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by "duhanmin (via GitHub)" <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r981938795


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -419,6 +438,58 @@ private String buildShellCommandFile(String jobConfigFilePath, Map<String, Prope
         return fileName;
     }
 
+    private String buildYarnShellCommandFile(String jobConfigFilePath, Map<String, Property> paramsMap, String dataxHdfsPath, String dataxOnYarnDependJar)

Review Comment:
   @EricGao888 Because yarn submission needs to use a lot of hadoop and yarn dependencies, it is easy to cause dependencies



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by "duhanmin (via GitHub)" <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r1168301335


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -94,6 +94,17 @@ public class DataxTask extends AbstractTaskExecutor {
      * datax path
      */
     private static final String DATAX_PATH = "${DATAX_HOME}/bin/datax.py";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_HDFS_PATH = "DATAX_HDFS_PATH";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_ON_YARN_DEPEND_JAR = "DATAX_ON_YARN_DEPEND_JAR";

Review Comment:
   @EricGao888 Have been added front options, associated pr https://github.com/apache/dolphinscheduler/pull/13937



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by "duhanmin (via GitHub)" <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r1168301335


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -94,6 +94,17 @@ public class DataxTask extends AbstractTaskExecutor {
      * datax path
      */
     private static final String DATAX_PATH = "${DATAX_HOME}/bin/datax.py";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_HDFS_PATH = "DATAX_HDFS_PATH";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_ON_YARN_DEPEND_JAR = "DATAX_ON_YARN_DEPEND_JAR";

Review Comment:
   @EricGao888 Have been added front options, associated pr https://github.com/apache/dolphinscheduler/pull/13939



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by "duhanmin (via GitHub)" <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r981939452


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -94,6 +94,17 @@ public class DataxTask extends AbstractTaskExecutor {
      * datax path
      */
     private static final String DATAX_PATH = "${DATAX_HOME}/bin/datax.py";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_HDFS_PATH = "DATAX_HDFS_PATH";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_ON_YARN_DEPEND_JAR = "DATAX_ON_YARN_DEPEND_JAR";

Review Comment:
   The front end is not very good at it. If you can pass a parameter from the front end, you can flexibly judge on the back end



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] EricGao888 commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
EricGao888 commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r979266781


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -419,6 +438,58 @@ private String buildShellCommandFile(String jobConfigFilePath, Map<String, Prope
         return fileName;
     }
 
+    private String buildYarnShellCommandFile(String jobConfigFilePath, Map<String, Property> paramsMap, String dataxHdfsPath, String dataxOnYarnDependJar)

Review Comment:
   Since the execution of many DS task plugins is based on `ShellCommandExecutor`, would u like to improve it so that those tasks could also run shell command in yarn containers? BTW, in this PR, it seems `datax-on-yarn-1.0.0.jar` is built from code in an individual repo and this might not be a good practice. https://github.com/apache/dolphinscheduler/blob/dev/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/ShellCommandExecutor.java



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by "duhanmin (via GitHub)" <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r1168301335


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -94,6 +94,17 @@ public class DataxTask extends AbstractTaskExecutor {
      * datax path
      */
     private static final String DATAX_PATH = "${DATAX_HOME}/bin/datax.py";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_HDFS_PATH = "DATAX_HDFS_PATH";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_ON_YARN_DEPEND_JAR = "DATAX_ON_YARN_DEPEND_JAR";

Review Comment:
   Have been added front options, associated pr https://github.com/apache/dolphinscheduler/pull/13937



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] EricGao888 commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
EricGao888 commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r979267425


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -419,6 +438,58 @@ private String buildShellCommandFile(String jobConfigFilePath, Map<String, Prope
         return fileName;
     }
 
+    private String buildYarnShellCommandFile(String jobConfigFilePath, Map<String, Property> paramsMap, String dataxHdfsPath, String dataxOnYarnDependJar)

Review Comment:
   The improvement of `ShellCommandExecutor` I mentioned above is just a suggestion not a requirement here. You don't need to do it in this PR : )



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r981938795


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -419,6 +438,58 @@ private String buildShellCommandFile(String jobConfigFilePath, Map<String, Prope
         return fileName;
     }
 
+    private String buildYarnShellCommandFile(String jobConfigFilePath, Map<String, Property> paramsMap, String dataxHdfsPath, String dataxOnYarnDependJar)

Review Comment:
   Because yarn submission needs to use a lot of hadoop and yarn dependencies, it is easy to cause dependencies



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin closed pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by "duhanmin (via GitHub)" <gi...@apache.org>.
duhanmin closed pull request #12106: [Feature-11488][Datax]Datax can submit to YARN
URL: https://github.com/apache/dolphinscheduler/pull/12106


-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by "duhanmin (via GitHub)" <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r981938795


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -419,6 +438,58 @@ private String buildShellCommandFile(String jobConfigFilePath, Map<String, Prope
         return fileName;
     }
 
+    private String buildYarnShellCommandFile(String jobConfigFilePath, Map<String, Property> paramsMap, String dataxHdfsPath, String dataxOnYarnDependJar)

Review Comment:
   @EricGao888 That's a good offer. I'll think about it



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] SbloodyS commented on pull request #12106: Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
SbloodyS commented on PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#issuecomment-1254792489

   Hi @duhanmin , please associate the issue and correct the title.


-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] EricGao888 commented on pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
EricGao888 commented on PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#issuecomment-1257001185

   @duhanmin Hello, thanks for submitting this PR and it's a good feature. I've added some comments and please take a look. 


-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [dolphinscheduler] duhanmin commented on a diff in pull request #12106: [Feature-11488][Datax]Datax can submit to YARN

Posted by GitBox <gi...@apache.org>.
duhanmin commented on code in PR #12106:
URL: https://github.com/apache/dolphinscheduler/pull/12106#discussion_r981939452


##########
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java:
##########
@@ -94,6 +94,17 @@ public class DataxTask extends AbstractTaskExecutor {
      * datax path
      */
     private static final String DATAX_PATH = "${DATAX_HOME}/bin/datax.py";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_HDFS_PATH = "DATAX_HDFS_PATH";
+
+    /**
+     * datax hdfs path
+     */
+    private static final String DATAX_ON_YARN_DEPEND_JAR = "DATAX_ON_YARN_DEPEND_JAR";

Review Comment:
   The front end is not very good at it. If you can pass a parameter from the front end, you can flexibly judge on the back end



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org