[ 
https://issues.apache.org/jira/browse/BEAM-5385?focusedWorklogId=144463&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-144463
 ]

ASF GitHub Bot logged work on BEAM-5385:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 14/Sep/18 20:49
            Start Date: 14/Sep/18 20:49
    Worklog Time Spent: 10m 
      Work Description: tweise closed pull request #6398: [BEAM-5385] Flink job 
server to use REST port from --flink-master-url instead of default.
URL: https://github.com/apache/beam/pull/6398
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git 
a/runners/flink/src/main/java/org/apache/beam/runners/flink/FlinkExecutionEnvironments.java
 
b/runners/flink/src/main/java/org/apache/beam/runners/flink/FlinkExecutionEnvironments.java
index 1162a7ed95a..9d16f3f55b7 100644
--- 
a/runners/flink/src/main/java/org/apache/beam/runners/flink/FlinkExecutionEnvironments.java
+++ 
b/runners/flink/src/main/java/org/apache/beam/runners/flink/FlinkExecutionEnvironments.java
@@ -21,6 +21,8 @@
 import java.util.List;
 import org.apache.flink.api.java.CollectionEnvironment;
 import org.apache.flink.api.java.ExecutionEnvironment;
+import org.apache.flink.configuration.Configuration;
+import org.apache.flink.configuration.RestOptions;
 import org.apache.flink.runtime.state.AbstractStateBackend;
 import org.apache.flink.streaming.api.TimeCharacteristic;
 import 
org.apache.flink.streaming.api.environment.CheckpointConfig.ExternalizedCheckpointCleanup;
@@ -101,10 +103,13 @@ public static StreamExecutionEnvironment 
createStreamExecutionEnvironment(
       flinkStreamEnv = StreamExecutionEnvironment.getExecutionEnvironment();
     } else if (masterUrl.matches(".*:\\d*")) {
       List<String> parts = Splitter.on(':').splitToList(masterUrl);
+      Configuration clientConfig = new Configuration();
+      clientConfig.setInteger(RestOptions.PORT, 
Integer.parseInt(parts.get(1)));
       flinkStreamEnv =
           StreamExecutionEnvironment.createRemoteEnvironment(
               parts.get(0),
               Integer.parseInt(parts.get(1)),
+              clientConfig,
               filesToStage.toArray(new String[filesToStage.size()]));
     } else {
       LOG.warn("Unrecognized Flink Master URL {}. Defaulting to [auto].", 
masterUrl);


 

----------------------------------------------------------------
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]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 144463)
    Time Spent: 40m  (was: 0.5h)

> Flink jobserver does not honor --flink-master-url
> -------------------------------------------------
>
>                 Key: BEAM-5385
>                 URL: https://issues.apache.org/jira/browse/BEAM-5385
>             Project: Beam
>          Issue Type: Bug
>          Components: runner-flink
>            Reporter: Thomas Weise
>            Assignee: Thomas Weise
>            Priority: Major
>              Labels: portability
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> It will use the external Flink cluster when specified, but only with default 
> port number 8081, because the actual port is not in propagated in 
> FlinkExecutionEnvironments (RestOptions.PORT setting).



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to