Wei H created FLINK-39310:
-----------------------------
Summary: Web UI jar.service.ts passes program-args as string
instead of programArgsList array, incompatible with Flink 2.0 REST API
Key: FLINK-39310
URL: https://issues.apache.org/jira/browse/FLINK-39310
Project: Flink
Issue Type: Bug
Affects Versions: 2.1.1, 2.2.0, 2.0.1, 2.0.0
Reporter: Wei H
The Web UI's {{jar.service.ts}} still passes program arguments as a single
string using the deprecated {{program-args}} field, which was replaced by
{{programArgsList}} (an array) in the Flink 2.0 REST API.
This means submitting a JAR with program arguments via the Web UI is broken on
Flink 2.0+.
*Affected file:*
{{flink-runtime-web/web-dashboard/src/app/services/jar.service.ts}}
*Affected methods:* {{runJob()}} and {{getPlan()}}
*Current (broken) behavior:*
{code:java}
public runJob(
jarId: string,
entryClass: string,
parallelism: string,
programArgs: string, // typed as plain string
...
) {
if (programArgs) {
params = params.append('program-args', programArgs); // sent as single
string
} {code}
*Expected behavior:* programArgs should be typed as string[] and sent as
programArgsList to match the Flink 2.0 REST API spec. Both runJob() and
getPlan() need to be updated.
Steps to reproduce:
Run Flink 2.0+
Open Web UI and navigate to Submit Job
Upload a JAR and enter program arguments
Submit — arguments are passed incorrectly and ignored or rejected by the REST
API{*}{*}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)