Hi Satyam,

for blink batch mode, only TableEnvironment can be used,
and TableEnvironment do not take StreamExecutionEnvironment as argument.
Instead StreamExecutionEnvironment instance is created internally.

back to your requirement, you can build your table program as user jar,
and submit the job through flink cli [1] to remote environment.

Bests,
Godfrey

[1] https://ci.apache.org/projects/flink/flink-docs-stable/ops/cli.html



Satyam Shekhar <satyamshek...@gmail.com> 于2020年6月3日周三 下午2:59写道:

> Hello,
>
> I am running into a very basic problem while working with Table API. I
> wish to create a TableEnvironment connected to a remote environment that
> uses Blink planner in batch mode. Examples and documentation I have come
> across so far recommend the following pattern to create such an environment
> -
>
> var settings = EnvironmentSettings.newInstance()
>                   .useBlinkPlanner()
>                   .inBatchMode()
>                   .build();
> var tEnv = TableEnvironment.create(settings);
>
> The above configuration, however, does not connect to a remote
> environment. Tracing code in TableEnvironment.java, I see the following
> method in BlinkExecutorFactory.java that appears to relevant -
>
> Executor create(Map<String, String>, StreamExecutionEnvironment);
>
> However, it seems to be only accessible through the Scala bridge. I can't
> seem to find a way to instantiate a TableEnvironment that takes
> StreamExecutionEnvironment as an argument. How do I achieve that?
>
> Regards,
> Satyam
>

Reply via email to