mxm commented on a change in pull request #7249: [FLINK-11048] Ability to
programmatically execute streaming pipeline with savepoint restore
URL: https://github.com/apache/flink/pull/7249#discussion_r242884359
##########
File path:
flink-streaming-java/src/main/java/org/apache/flink/streaming/api/environment/RemoteStreamEnvironment.java
##########
@@ -169,33 +173,66 @@ public RemoteStreamEnvironment(String host, int port,
Configuration clientConfig
}
}
- @Override
- public JobExecutionResult execute(String jobName) throws
ProgramInvocationException {
- StreamGraph streamGraph = getStreamGraph();
- streamGraph.setJobName(jobName);
- transformations.clear();
- return executeRemotely(streamGraph, jarFiles);
+ /**
+ * Set savepoint restore settings that will be used when executing the
job.
+ * @param savepointRestoreSettings savepoint restore settings
+ */
+ public void setSavepointRestoreSettings(SavepointRestoreSettings
savepointRestoreSettings) {
+ this.savepointRestoreSettings = savepointRestoreSettings;
Review comment:
To be fair the code above has been changed, it's not a setter anymore but
set in the constructor. You summed up quite nicely what is actually the state
of this PR now. Nothing is broken in terms of backwards-compatibility but the
structure changed a bit which makes it hard to review. The only difference is
that an additional constructor has been added for the savepoint settings
instead of this method you proposed:
```
public JobExecutionResult execute(String jobName, SavepointRestoreSettings
savepointRestoreSettings) throws ProgramInvocationException {
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services