tfx.orchestration.launcher.kubernetes_component_launcher.KubernetesComponentLauncher

Responsible for launching a container executor on Kubernetes.

Inherits From: BaseComponentLauncher

component The Tfx node to launch.
pipeline_info An instance of data_types.PipelineInfo that holds pipeline properties.
driver_args An instance of data_types.DriverArgs that holds component specific driver args.
metadata_connection ML metadata connection. The connection is expected to not be opened when given to this object.
beam_pipeline_args Pipeline arguments for Beam powered Components.
additional_pipeline_args Additional pipeline args.
component_config Optional component specific config to instrument launcher on how to launch a component.

ValueError when component and component_config are not launchable by the launcher.

Methods

can_launch

View source

Checks if the launcher can launch the executor spec.

create

View source

Initialize a ComponentLauncher directly from a BaseComponent instance.

This class method is the contract between TfxRunner and BaseComponentLauncher to support launcher polymorphism. Sublcass of this class must make sure it can be initialized by the method.

Args
component The component to launch.
pipeline_info An instance of data_types.PipelineInfo that holds pipeline properties.
driver_args An instance of data_types.DriverArgs that holds component specific driver args.
metadata_connection ML metadata connection. The connection is expected to not be opened when given to this object.
beam_pipeline_args Pipeline arguments for Beam powered Components.
additional_pipeline_args Additional pipeline args.
component_config Optional component specific config to instrument launcher on how to launch a component.

Returns
A new instance of component launcher.

launch

View source

Execute the component, includes driver, executor and publisher.

Returns
The execution decision of the launch.