Class DetachedApplicationRunner
- java.lang.Object
-
- org.apache.flink.client.deployment.application.DetachedApplicationRunner
-
- All Implemented Interfaces:
ApplicationRunner
@Internal public class DetachedApplicationRunner extends Object implements ApplicationRunner
AnApplicationRunner
which runs the user specified application using theEmbeddedExecutor
. This runner invokes methods of the providedDispatcherGateway
directly, and it does not go through the REST API.In addition, this runner does not wait for the application to finish, but it submits the application in a
DETACHED
mode. As a consequence, applications with jobs that rely on operations like[collect, print, printToErr, count]
will fail.
-
-
Constructor Summary
Constructors Constructor Description DetachedApplicationRunner(boolean enforceSingleJobExecution)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<JobID>
run(DispatcherGateway dispatcherGateway, PackagedProgram program, Configuration configuration)
Runs the application using the provideddispatcherGateway
.
-
-
-
Method Detail
-
run
public List<JobID> run(DispatcherGateway dispatcherGateway, PackagedProgram program, Configuration configuration)
Description copied from interface:ApplicationRunner
Runs the application using the provideddispatcherGateway
.- Specified by:
run
in interfaceApplicationRunner
- Parameters:
dispatcherGateway
- the dispatcher of the cluster to run the application.program
- thePackagedProgram
containing the user's main method.configuration
- the configuration used to run the application.- Returns:
- a list of the submitted jobs that belong to the provided application.
-
-