{{ message }}
Repository navigation
Conversation
Submit SQL scripts to a Flink SQL Gateway via its JDBC driver: - main/init SQL from inline script or resource-center file (reuses task-api SqlSourceType enum) - configurable statement separator, leading comment/blank stripping - parameter placeholders supported in jdbc url and scripts - plain JUnit tests, no Mockito Named FLINK_SGW because FLINK_SQL_GATEWAY is too long for the DAG node / task-type picker layout (reuses the Flink family icon).
macdoor
requested review from
Gallardot,
SbloodyS and
caishunfeng
as code owners
October 10, 2026 03:45
vue-tsc rejects the task model otherwise; the field is used by the SQL Gateway form and was missing from ITaskParams.
SbloodyS
requested changes
Oct 10, 2026
SbloodyS
left a comment
Member
There was a problem hiding this comment.
You should integrate it into flink task plugin.
Contributor
Author
Member
|
I'm -1 on this. |
This was referenced Oct 10, 2026
Contributor
Author
|
Integrated this into the existing FLINK task plugin, as requested.
Closing this PR. |
Contributor
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Was this PR generated or assisted by AI?
YES — the plugin code was initially developed with AI-assisted tooling (Cursor) and this port/adaptation (rebasing onto dev-SNAPSHOT, adopting the
SqlSourceTypeenum from task-api, refactor for testability, and unit-test authoring) was assisted by an AI agent (Hermes). All changes were human-reviewed and verified by build + unit tests.Purpose of the pull request
Add a new task plugin FLINK_SGW that submits SQL scripts to a Flink SQL Gateway through its JDBC driver (
flink-sql-jdbc-driver), enabling DolphinScheduler to schedule batch SQL workloads without a local Flink client.The task type is named
FLINK_SGWinstead of the longerFLINK_SQL_GATEWAY: the long name wraps and breaks the DAG node / task-type picker layout; the short alias reuses the Flink family icon and keeps nodes readable (see linked issue).Brief change log
dolphinscheduler-task-flink-sqlgatewaymodule (FlinkSqlGatewayParameters/FlinkSqlGatewayTask/FlinkSqlGatewayTaskChannel/FlinkSqlGatewayTaskChannelFactory)dolphinscheduler-task-plugin/pom.xmland wire it intodolphinscheduler-task-allFLINK_SGWintask-type-config.yamluse-flink-sqlgateway), format-data serialization, icon fallback (reuseflink.png), locales (en/zh)use-resourcesfield helper gains optionallimit/fieldparameters to support the init-script resource fieldDesign notes:
org.apache.dolphinscheduler.plugin.task.api.enums.SqlSourceType(SCRIPT/FILE) introduced by [Improvement-18019][task-sql] Support SQL from resource file and parameter placeholders #18020, instead of duplicating constantstask-api/commonstayprovidedVerify this pull request
This change added tests and can be verified as follows:
mvn test -pl dolphinscheduler-task-plugin/dolphinscheduler-task-flink-sqlgateway -am—FlinkSqlGatewayParametersTest(12 checks: parameter validation across SCRIPT/FILE combinations, resource aggregation, JDBC property filtering) andFlinkSqlGatewayTaskTest(statement splitting incl. regex-special separators, leading comment/blank stripping)mvn package -pl dolphinscheduler-task-plugin/dolphinscheduler-task-flink-sqlgateway -ambuilds the shaded jar cleanly