You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dolphinscheduler.apache.org by jo...@apache.org on 2020/07/23 02:28:34 UTC

[incubator-dolphinscheduler-maven-plugin] 19/34: add why we need this maven plugin

This is an automated email from the ASF dual-hosted git repository.

journey pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-dolphinscheduler-maven-plugin.git

commit 2078bafb2e6cce6791a73652bebbf9d1bf580de5
Author: gaojun2048 <54...@qq.com>
AuthorDate: Wed Jun 24 18:18:28 2020 +0800

    add why we need this maven plugin
---
 README.md | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/README.md b/README.md
index 2210973..7661f40 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-This is a maven plugin for DolphinScheduler , It has three functions:
+### This is a maven plugin for DolphinScheduler , It has three functions:
 
 1. It is allowed to add <packaging>dolphinscheduler-plugin</packaging> to the pom file. If <packaging>dolphinscheduler-plugin</packaging> is added to the pom file, the DolphinScheduler service will load this model as a DolphinScheduler plugin.
 
@@ -6,3 +6,10 @@ This is a maven plugin for DolphinScheduler , It has three functions:
 
 3. Automatically check DolphinScheduler's maven dependency. Especially the dependencies used by plugins.
 
+### Why we need this maven plugin?
+
+If we are running on the server deployment. Because the plug-ins are in the corresponding plug-in directory, and the plug-in jar package has the corresponding META-INF/services, there is no problem. 
+
+However, when we develop locally in IDE, we have no plug-ins dir and no plug-ins jar file . If we want to test and debug the plugin code, we need add the plugin module to the pom.xml of alert module ,But this violates the original intention of SPI. So we can`t add the plug-in module to the alert module as a dependency, So there will be a problem that the alert module cannot find the plug-in classes. 
+
+With this maven plug-in, by scanning the pom file of the project ,The pluginloader can find the module identified by <package>dolphinscheduler-plugin</package>, then can load this module`s class files and its dependent third-party jars from the target/classes dir of the plug-in module. This will debug locally