Interface FlinkService

    • Method Detail

      • getKubernetesClient

        io.fabric8.kubernetes.client.KubernetesClient getKubernetesClient()
      • submitApplicationCluster

        void submitApplicationCluster​(JobSpec jobSpec,
                                      org.apache.flink.configuration.Configuration conf,
                                      boolean requireHaMetadata)
                               throws java.lang.Exception
        Throws:
        java.lang.Exception
      • isHaMetadataAvailable

        boolean isHaMetadataAvailable​(org.apache.flink.configuration.Configuration conf)
      • submitSessionCluster

        void submitSessionCluster​(org.apache.flink.configuration.Configuration conf)
                           throws java.lang.Exception
        Throws:
        java.lang.Exception
      • submitJobToSessionCluster

        org.apache.flink.api.common.JobID submitJobToSessionCluster​(io.fabric8.kubernetes.api.model.ObjectMeta meta,
                                                                    FlinkSessionJobSpec spec,
                                                                    org.apache.flink.configuration.Configuration conf,
                                                                    @Nullable
                                                                    java.lang.String savepoint)
                                                             throws java.lang.Exception
        Throws:
        java.lang.Exception
      • isJobManagerPortReady

        boolean isJobManagerPortReady​(org.apache.flink.configuration.Configuration config)
      • listJobs

        java.util.Collection<org.apache.flink.runtime.client.JobStatusMessage> listJobs​(org.apache.flink.configuration.Configuration conf)
                                                                                 throws java.lang.Exception
        Throws:
        java.lang.Exception
      • requestJobResult

        org.apache.flink.runtime.jobmaster.JobResult requestJobResult​(org.apache.flink.configuration.Configuration conf,
                                                                      org.apache.flink.api.common.JobID jobID)
                                                               throws java.lang.Exception
        Throws:
        java.lang.Exception
      • cancelJob

        void cancelJob​(FlinkDeployment deployment,
                       UpgradeMode upgradeMode,
                       org.apache.flink.configuration.Configuration conf)
                throws java.lang.Exception
        Throws:
        java.lang.Exception
      • deleteClusterDeployment

        void deleteClusterDeployment​(io.fabric8.kubernetes.api.model.ObjectMeta meta,
                                     FlinkDeploymentStatus status,
                                     boolean deleteHaData)
      • cancelSessionJob

        void cancelSessionJob​(FlinkSessionJob sessionJob,
                              UpgradeMode upgradeMode,
                              org.apache.flink.configuration.Configuration conf)
                       throws java.lang.Exception
        Throws:
        java.lang.Exception
      • triggerSavepoint

        void triggerSavepoint​(java.lang.String jobId,
                              SavepointTriggerType triggerType,
                              SavepointInfo savepointInfo,
                              org.apache.flink.configuration.Configuration conf)
                       throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getLastCheckpoint

        java.util.Optional<Savepoint> getLastCheckpoint​(org.apache.flink.api.common.JobID jobId,
                                                        org.apache.flink.configuration.Configuration conf)
                                                 throws java.lang.Exception
        Throws:
        java.lang.Exception
      • fetchSavepointInfo

        SavepointFetchResult fetchSavepointInfo​(java.lang.String triggerId,
                                                java.lang.String jobId,
                                                org.apache.flink.configuration.Configuration conf)
      • disposeSavepoint

        void disposeSavepoint​(java.lang.String savepointPath,
                              org.apache.flink.configuration.Configuration conf)
                       throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getClusterInfo

        java.util.Map<java.lang.String,​java.lang.String> getClusterInfo​(org.apache.flink.configuration.Configuration conf)
                                                                       throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getJmPodList

        io.fabric8.kubernetes.api.model.PodList getJmPodList​(FlinkDeployment deployment,
                                                             org.apache.flink.configuration.Configuration conf)
      • waitForClusterShutdown

        void waitForClusterShutdown​(org.apache.flink.configuration.Configuration conf)
      • scale

        default boolean scale​(io.fabric8.kubernetes.api.model.ObjectMeta meta,
                              JobSpec jobSpec,
                              org.apache.flink.configuration.Configuration conf)
      • getMetrics

        java.util.Map<java.lang.String,​java.lang.String> getMetrics​(org.apache.flink.configuration.Configuration conf,
                                                                          java.lang.String jobId,
                                                                          java.util.List<java.lang.String> metricNames)
                                                                   throws java.lang.Exception
        Throws:
        java.lang.Exception