java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.kinesisanalytics.flink.alpha.Application
All Implemented Interfaces:
IResource, IConnectable, IGrantable, IApplication, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.97.0 (build 729de35)", date="2024-04-18T17:54:26.779Z") @Stability(Experimental) public class Application extends Resource implements IApplication
(experimental) The L2 construct for Flink Kinesis Data Applications.

Example:

 import path.*;
 import software.amazon.awscdk.services.cloudwatch.*;
 import software.amazon.awscdk.*;
 import software.amazon.awscdk.services.kinesisanalytics.flink.alpha.*;
 App app = new App();
 Stack stack = new Stack(app, "FlinkAppTest");
 Application flinkApp = Application.Builder.create(stack, "App")
         .code(ApplicationCode.fromAsset(join(__dirname, "code-asset")))
         .runtime(Runtime.FLINK_1_18)
         .build();
 Alarm.Builder.create(stack, "Alarm")
         .metric(flinkApp.metricFullRestarts())
         .evaluationPeriods(1)
         .threshold(3)
         .build();
 app.synth();
 
  • Constructor Details

    • Application

      protected Application(software.amazon.jsii.JsiiObjectRef objRef)
    • Application

      protected Application(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • Application

      @Stability(Experimental) public Application(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull ApplicationProps props)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      props - This parameter is required.
  • Method Details

    • fromApplicationArn

      @Stability(Experimental) @NotNull public static IApplication fromApplicationArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String applicationArn)
      (experimental) Import an existing application defined outside of CDK code by applicationArn.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      applicationArn - This parameter is required.
    • fromApplicationAttributes

      @Stability(Experimental) @NotNull public static IApplication fromApplicationAttributes(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull ApplicationAttributes attrs)
      (experimental) Import an existing application defined outside of CDK code.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      attrs - This parameter is required.
    • fromApplicationName

      @Stability(Experimental) @NotNull public static IApplication fromApplicationName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String applicationName)
      (experimental) Import an existing Flink application defined outside of CDK code by applicationName.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      applicationName - This parameter is required.
    • addToRolePolicy

      @Stability(Experimental) @NotNull public Boolean addToRolePolicy(@NotNull PolicyStatement policyStatement)
      (experimental) Implement the convenience IApplication.addToPrincipalPolicy method.

      Specified by:
      addToRolePolicy in interface IApplication
      Parameters:
      policyStatement - This parameter is required.
    • metric

      @Stability(Experimental) @NotNull public Metric metric(@NotNull String metricName, @Nullable MetricOptions props)
      (experimental) Return a CloudWatch metric associated with this Flink application.

      Specified by:
      metric in interface IApplication
      Parameters:
      metricName - The name of the metric. This parameter is required.
      props - Customization properties.
    • metric

      @Stability(Experimental) @NotNull public Metric metric(@NotNull String metricName)
      (experimental) Return a CloudWatch metric associated with this Flink application.

      Specified by:
      metric in interface IApplication
      Parameters:
      metricName - The name of the metric. This parameter is required.
    • metricBackPressuredTimeMsPerSecond

      @Stability(Experimental) @NotNull public Metric metricBackPressuredTimeMsPerSecond(@Nullable MetricOptions props)
      (experimental) The time (in milliseconds) this task or operator is back pressured per second.

      Units: Milliseconds

      Reporting Level: Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricBackPressuredTimeMsPerSecond in interface IApplication
      Parameters:
      props -
    • metricBackPressuredTimeMsPerSecond

      @Stability(Experimental) @NotNull public Metric metricBackPressuredTimeMsPerSecond()
      (experimental) The time (in milliseconds) this task or operator is back pressured per second.

      Units: Milliseconds

      Reporting Level: Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricBackPressuredTimeMsPerSecond in interface IApplication
    • metricBusyTimePerMsPerSecond

      @Stability(Experimental) @NotNull public Metric metricBusyTimePerMsPerSecond(@Nullable MetricOptions props)
      (experimental) The time (in milliseconds) this task or operator is busy (neither idle nor back pressured) per second.

      Can be NaN, if the value could not be calculated.

      Units: Milliseconds

      Reporting Level: Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricBusyTimePerMsPerSecond in interface IApplication
      Parameters:
      props -
    • metricBusyTimePerMsPerSecond

      @Stability(Experimental) @NotNull public Metric metricBusyTimePerMsPerSecond()
      (experimental) The time (in milliseconds) this task or operator is busy (neither idle nor back pressured) per second.

      Can be NaN, if the value could not be calculated.

      Units: Milliseconds

      Reporting Level: Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricBusyTimePerMsPerSecond in interface IApplication
    • metricCpuUtilization

      @Stability(Experimental) @NotNull public Metric metricCpuUtilization(@Nullable MetricOptions props)
      (experimental) The overall percentage of CPU utilization across task managers.

      For example, if there are five task managers, Kinesis Data Analytics publishes five samples of this metric per reporting interval.

      Units: Percentage

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricCpuUtilization in interface IApplication
      Parameters:
      props -
    • metricCpuUtilization

      @Stability(Experimental) @NotNull public Metric metricCpuUtilization()
      (experimental) The overall percentage of CPU utilization across task managers.

      For example, if there are five task managers, Kinesis Data Analytics publishes five samples of this metric per reporting interval.

      Units: Percentage

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricCpuUtilization in interface IApplication
    • metricCurrentInputWatermark

      @Stability(Experimental) @NotNull public Metric metricCurrentInputWatermark(@Nullable MetricOptions props)
      (experimental) The last watermark this application/operator/task/thread has received.

      Units: Milliseconds

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - maximum over 5 minutes

      Specified by:
      metricCurrentInputWatermark in interface IApplication
      Parameters:
      props -
    • metricCurrentInputWatermark

      @Stability(Experimental) @NotNull public Metric metricCurrentInputWatermark()
      (experimental) The last watermark this application/operator/task/thread has received.

      Units: Milliseconds

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - maximum over 5 minutes

      Specified by:
      metricCurrentInputWatermark in interface IApplication
    • metricCurrentOutputWatermark

      @Stability(Experimental) @NotNull public Metric metricCurrentOutputWatermark(@Nullable MetricOptions props)
      (experimental) The last watermark this application/operator/task/thread has received.

      Units: Milliseconds

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - maximum over 5 minutes

      Specified by:
      metricCurrentOutputWatermark in interface IApplication
      Parameters:
      props -
    • metricCurrentOutputWatermark

      @Stability(Experimental) @NotNull public Metric metricCurrentOutputWatermark()
      (experimental) The last watermark this application/operator/task/thread has received.

      Units: Milliseconds

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - maximum over 5 minutes

      Specified by:
      metricCurrentOutputWatermark in interface IApplication
    • metricDowntime

      @Stability(Experimental) @NotNull public Metric metricDowntime(@Nullable MetricOptions props)
      (experimental) The time elapsed during an outage for failing/recovering jobs.

      Units: Milliseconds

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricDowntime in interface IApplication
      Parameters:
      props -
    • metricDowntime

      @Stability(Experimental) @NotNull public Metric metricDowntime()
      (experimental) The time elapsed during an outage for failing/recovering jobs.

      Units: Milliseconds

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricDowntime in interface IApplication
    • metricFullRestarts

      @Stability(Experimental) @NotNull public Metric metricFullRestarts(@Nullable MetricOptions props)
      (experimental) The total number of times this job has fully restarted since it was submitted.

      This metric does not measure fine-grained restarts.

      Units: Count

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricFullRestarts in interface IApplication
      Parameters:
      props -
    • metricFullRestarts

      @Stability(Experimental) @NotNull public Metric metricFullRestarts()
      (experimental) The total number of times this job has fully restarted since it was submitted.

      This metric does not measure fine-grained restarts.

      Units: Count

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricFullRestarts in interface IApplication
    • metricHeapMemoryUtilization

      @Stability(Experimental) @NotNull public Metric metricHeapMemoryUtilization(@Nullable MetricOptions props)
      (experimental) Overall heap memory utilization across task managers.

      For example, if there are five task managers, Kinesis Data Analytics publishes five samples of this metric per reporting interval.

      Units: Percentage

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricHeapMemoryUtilization in interface IApplication
      Parameters:
      props -
    • metricHeapMemoryUtilization

      @Stability(Experimental) @NotNull public Metric metricHeapMemoryUtilization()
      (experimental) Overall heap memory utilization across task managers.

      For example, if there are five task managers, Kinesis Data Analytics publishes five samples of this metric per reporting interval.

      Units: Percentage

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricHeapMemoryUtilization in interface IApplication
    • metricIdleTimeMsPerSecond

      @Stability(Experimental) @NotNull public Metric metricIdleTimeMsPerSecond(@Nullable MetricOptions props)
      (experimental) The time (in milliseconds) this task or operator is idle (has no data to process) per second.

      Idle time excludes back pressured time, so if the task is back pressured it is not idle.

      Units: Milliseconds

      Reporting Level: Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricIdleTimeMsPerSecond in interface IApplication
      Parameters:
      props -
    • metricIdleTimeMsPerSecond

      @Stability(Experimental) @NotNull public Metric metricIdleTimeMsPerSecond()
      (experimental) The time (in milliseconds) this task or operator is idle (has no data to process) per second.

      Idle time excludes back pressured time, so if the task is back pressured it is not idle.

      Units: Milliseconds

      Reporting Level: Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricIdleTimeMsPerSecond in interface IApplication
    • metricKpus

      @Stability(Experimental) @NotNull public Metric metricKpus(@Nullable MetricOptions props)
      (experimental) The number of Kinesis Processing Units that are used to run your stream processing application.

      The average number of KPUs used each hour determines the billing for your application.

      Units: Count

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricKpus in interface IApplication
      Parameters:
      props -
    • metricKpus

      @Stability(Experimental) @NotNull public Metric metricKpus()
      (experimental) The number of Kinesis Processing Units that are used to run your stream processing application.

      The average number of KPUs used each hour determines the billing for your application.

      Units: Count

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricKpus in interface IApplication
    • metricLastCheckpointDuration

      @Stability(Experimental) @NotNull public Metric metricLastCheckpointDuration(@Nullable MetricOptions props)
      (experimental) The time it took to complete the last checkpoint.

      Units: Milliseconds

      Reporting Level: Application

      Default: - maximum over 5 minutes

      Specified by:
      metricLastCheckpointDuration in interface IApplication
      Parameters:
      props -
    • metricLastCheckpointDuration

      @Stability(Experimental) @NotNull public Metric metricLastCheckpointDuration()
      (experimental) The time it took to complete the last checkpoint.

      Units: Milliseconds

      Reporting Level: Application

      Default: - maximum over 5 minutes

      Specified by:
      metricLastCheckpointDuration in interface IApplication
    • metricLastCheckpointSize

      @Stability(Experimental) @NotNull public Metric metricLastCheckpointSize(@Nullable MetricOptions props)
      (experimental) The total size of the last checkpoint.

      Units: Bytes

      Reporting Level: Application

      Default: - maximum over 5 minutes

      Specified by:
      metricLastCheckpointSize in interface IApplication
      Parameters:
      props -
    • metricLastCheckpointSize

      @Stability(Experimental) @NotNull public Metric metricLastCheckpointSize()
      (experimental) The total size of the last checkpoint.

      Units: Bytes

      Reporting Level: Application

      Default: - maximum over 5 minutes

      Specified by:
      metricLastCheckpointSize in interface IApplication
    • metricManagedMemoryTotal

      @Stability(Experimental) @NotNull public Metric metricManagedMemoryTotal(@Nullable MetricOptions props)
      (experimental) The total amount of managed memory.

      Units: Bytes

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricManagedMemoryTotal in interface IApplication
      Parameters:
      props -
    • metricManagedMemoryTotal

      @Stability(Experimental) @NotNull public Metric metricManagedMemoryTotal()
      (experimental) The total amount of managed memory.

      Units: Bytes

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricManagedMemoryTotal in interface IApplication
    • metricManagedMemoryUsed

      @Stability(Experimental) @NotNull public Metric metricManagedMemoryUsed(@Nullable MetricOptions props)
      (experimental) The amount of managed memory currently used.

      Units: Bytes

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricManagedMemoryUsed in interface IApplication
      Parameters:
      props -
    • metricManagedMemoryUsed

      @Stability(Experimental) @NotNull public Metric metricManagedMemoryUsed()
      (experimental) The amount of managed memory currently used.

      Units: Bytes

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricManagedMemoryUsed in interface IApplication
    • metricManagedMemoryUtilization

      @Stability(Experimental) @NotNull public Metric metricManagedMemoryUtilization(@Nullable MetricOptions props)
      (experimental) Derived from managedMemoryUsed/managedMemoryTotal.

      Units: Percentage

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricManagedMemoryUtilization in interface IApplication
      Parameters:
      props -
    • metricManagedMemoryUtilization

      @Stability(Experimental) @NotNull public Metric metricManagedMemoryUtilization()
      (experimental) Derived from managedMemoryUsed/managedMemoryTotal.

      Units: Percentage

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricManagedMemoryUtilization in interface IApplication
    • metricNumberOfFailedCheckpoints

      @Stability(Experimental) @NotNull public Metric metricNumberOfFailedCheckpoints(@Nullable MetricOptions props)
      (experimental) The number of times checkpointing has failed.

      Units: Count

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricNumberOfFailedCheckpoints in interface IApplication
      Parameters:
      props -
    • metricNumberOfFailedCheckpoints

      @Stability(Experimental) @NotNull public Metric metricNumberOfFailedCheckpoints()
      (experimental) The number of times checkpointing has failed.

      Units: Count

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricNumberOfFailedCheckpoints in interface IApplication
    • metricNumLateRecordsDropped

      @Stability(Experimental) @NotNull public Metric metricNumLateRecordsDropped(@Nullable MetricOptions props)
      (experimental) The number of records this operator or task has dropped due to arriving late.

      Units: Count

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - sum over 5 minutes

      Specified by:
      metricNumLateRecordsDropped in interface IApplication
      Parameters:
      props -
    • metricNumLateRecordsDropped

      @Stability(Experimental) @NotNull public Metric metricNumLateRecordsDropped()
      (experimental) The number of records this operator or task has dropped due to arriving late.

      Units: Count

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - sum over 5 minutes

      Specified by:
      metricNumLateRecordsDropped in interface IApplication
    • metricNumRecordsIn

      @Stability(Experimental) @NotNull public Metric metricNumRecordsIn(@Nullable MetricOptions props)
      (experimental) The total number of records this application, operator, or task has received.

      Units: Count

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsIn in interface IApplication
      Parameters:
      props -
    • metricNumRecordsIn

      @Stability(Experimental) @NotNull public Metric metricNumRecordsIn()
      (experimental) The total number of records this application, operator, or task has received.

      Units: Count

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsIn in interface IApplication
    • metricNumRecordsInPerSecond

      @Stability(Experimental) @NotNull public Metric metricNumRecordsInPerSecond(@Nullable MetricOptions props)
      (experimental) The total number of records this application, operator or task has received per second.

      Units: Count/Second

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsInPerSecond in interface IApplication
      Parameters:
      props -
    • metricNumRecordsInPerSecond

      @Stability(Experimental) @NotNull public Metric metricNumRecordsInPerSecond()
      (experimental) The total number of records this application, operator or task has received per second.

      Units: Count/Second

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsInPerSecond in interface IApplication
    • metricNumRecordsOut

      @Stability(Experimental) @NotNull public Metric metricNumRecordsOut(@Nullable MetricOptions props)
      (experimental) The total number of records this application, operator or task has emitted.

      Units: Count

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsOut in interface IApplication
      Parameters:
      props -
    • metricNumRecordsOut

      @Stability(Experimental) @NotNull public Metric metricNumRecordsOut()
      (experimental) The total number of records this application, operator or task has emitted.

      Units: Count

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsOut in interface IApplication
    • metricNumRecordsOutPerSecond

      @Stability(Experimental) @NotNull public Metric metricNumRecordsOutPerSecond(@Nullable MetricOptions props)
      (experimental) The total number of records this application, operator or task has emitted per second.

      Units: Count/Second

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsOutPerSecond in interface IApplication
      Parameters:
      props -
    • metricNumRecordsOutPerSecond

      @Stability(Experimental) @NotNull public Metric metricNumRecordsOutPerSecond()
      (experimental) The total number of records this application, operator or task has emitted per second.

      Units: Count/Second

      Reporting Level: Application, Operator, Task, Parallelism

      Default: - average over 5 minutes

      Specified by:
      metricNumRecordsOutPerSecond in interface IApplication
    • metricOldGenerationGCCount

      @Stability(Experimental) @NotNull public Metric metricOldGenerationGCCount(@Nullable MetricOptions props)
      (experimental) The total number of old garbage collection operations that have occurred across all task managers.

      Units: Count

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricOldGenerationGCCount in interface IApplication
      Parameters:
      props -
    • metricOldGenerationGCCount

      @Stability(Experimental) @NotNull public Metric metricOldGenerationGCCount()
      (experimental) The total number of old garbage collection operations that have occurred across all task managers.

      Units: Count

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricOldGenerationGCCount in interface IApplication
    • metricOldGenerationGCTime

      @Stability(Experimental) @NotNull public Metric metricOldGenerationGCTime(@Nullable MetricOptions props)
      (experimental) The total time spent performing old garbage collection operations.

      Units: Milliseconds

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricOldGenerationGCTime in interface IApplication
      Parameters:
      props -
    • metricOldGenerationGCTime

      @Stability(Experimental) @NotNull public Metric metricOldGenerationGCTime()
      (experimental) The total time spent performing old garbage collection operations.

      Units: Milliseconds

      Reporting Level: Application

      Default: - sum over 5 minutes

      Specified by:
      metricOldGenerationGCTime in interface IApplication
    • metricThreadsCount

      @Stability(Experimental) @NotNull public Metric metricThreadsCount(@Nullable MetricOptions props)
      (experimental) The total number of live threads used by the application.

      Units: Count

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricThreadsCount in interface IApplication
      Parameters:
      props -
    • metricThreadsCount

      @Stability(Experimental) @NotNull public Metric metricThreadsCount()
      (experimental) The total number of live threads used by the application.

      Units: Count

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricThreadsCount in interface IApplication
    • metricUptime

      @Stability(Experimental) @NotNull public Metric metricUptime(@Nullable MetricOptions props)
      (experimental) The time that the job has been running without interruption.

      Units: Milliseconds

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricUptime in interface IApplication
      Parameters:
      props -
    • metricUptime

      @Stability(Experimental) @NotNull public Metric metricUptime()
      (experimental) The time that the job has been running without interruption.

      Units: Milliseconds

      Reporting Level: Application

      Default: - average over 5 minutes

      Specified by:
      metricUptime in interface IApplication
    • getApplicationArn

      @Stability(Experimental) @NotNull public String getApplicationArn()
      (experimental) The application ARN.
      Specified by:
      getApplicationArn in interface IApplication
    • getApplicationName

      @Stability(Experimental) @NotNull public String getApplicationName()
      (experimental) The name of the Flink application.
      Specified by:
      getApplicationName in interface IApplication
    • getConnections

      @Stability(Experimental) @NotNull public Connections getConnections()
      (experimental) The network connections associated with this resource.
      Specified by:
      getConnections in interface IConnectable
    • getGrantPrincipal

      @Stability(Experimental) @NotNull public IPrincipal getGrantPrincipal()
      (experimental) The principal to grant permissions to.
      Specified by:
      getGrantPrincipal in interface IGrantable
    • getRole

      @Stability(Experimental) @Nullable public IRole getRole()
      (experimental) The application IAM role.
      Specified by:
      getRole in interface IApplication