java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.kinesisfirehose.alpha.DeliveryStream
All Implemented Interfaces:
IResource, IConnectable, IGrantable, IDeliveryStream, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.101.0 (build b95fe5d)", date="2024-07-11T03:46:03.576Z") @Stability(Experimental) public class DeliveryStream extends Resource implements IDeliveryStream
(experimental) Create a Kinesis Data Firehose delivery stream.

Example:

 import software.amazon.awscdk.services.kinesisfirehose.alpha.*;
 import software.amazon.awscdk.services.kinesisfirehose.destinations.alpha.*;
 Bucket bucket = new Bucket(this, "MyBucket");
 DeliveryStream stream = DeliveryStream.Builder.create(this, "MyStream")
         .destinations(List.of(new S3Bucket(bucket)))
         .build();
 TopicRule topicRule = TopicRule.Builder.create(this, "TopicRule")
         .sql(IotSql.fromStringAsVer20160323("SELECT * FROM 'device/+/data'"))
         .actions(List.of(
             FirehosePutRecordAction.Builder.create(stream)
                     .batchMode(true)
                     .recordSeparator(FirehoseRecordSeparator.NEWLINE)
                     .build()))
         .build();
 
  • Constructor Details

    • DeliveryStream

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

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

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

    • fromDeliveryStreamArn

      @Stability(Experimental) @NotNull public static IDeliveryStream fromDeliveryStreamArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String deliveryStreamArn)
      (experimental) Import an existing delivery stream from its ARN.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      deliveryStreamArn - This parameter is required.
    • fromDeliveryStreamAttributes

      @Stability(Experimental) @NotNull public static IDeliveryStream fromDeliveryStreamAttributes(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull DeliveryStreamAttributes attrs)
      (experimental) Import an existing delivery stream from its attributes.

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

      @Stability(Experimental) @NotNull public static IDeliveryStream fromDeliveryStreamName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String deliveryStreamName)
      (experimental) Import an existing delivery stream from its name.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      deliveryStreamName - This parameter is required.
    • grant

      @Stability(Experimental) @NotNull public Grant grant(@NotNull IGrantable grantee, @NotNull @NotNull String... actions)
      (experimental) Grant the grantee identity permissions to perform actions.

      Specified by:
      grant in interface IDeliveryStream
      Parameters:
      grantee - This parameter is required.
      actions - This parameter is required.
    • grantPutRecords

      @Stability(Experimental) @NotNull public Grant grantPutRecords(@NotNull IGrantable grantee)
      (experimental) Grant the grantee identity permissions to perform firehose:PutRecord and firehose:PutRecordBatch actions on this delivery stream.

      Specified by:
      grantPutRecords in interface IDeliveryStream
      Parameters:
      grantee - This parameter is required.
    • metric

      @Stability(Experimental) @NotNull public Metric metric(@NotNull String metricName, @Nullable MetricOptions props)
      (experimental) Return the given named metric for this delivery stream.

      Specified by:
      metric in interface IDeliveryStream
      Parameters:
      metricName - This parameter is required.
      props -
    • metric

      @Stability(Experimental) @NotNull public Metric metric(@NotNull String metricName)
      (experimental) Return the given named metric for this delivery stream.

      Specified by:
      metric in interface IDeliveryStream
      Parameters:
      metricName - This parameter is required.
    • metricBackupToS3Bytes

      @Stability(Experimental) @NotNull public Metric metricBackupToS3Bytes(@Nullable MetricOptions props)
      (experimental) Metric for the number of bytes delivered to Amazon S3 for backup over the specified time period.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricBackupToS3Bytes in interface IDeliveryStream
      Parameters:
      props -
    • metricBackupToS3Bytes

      @Stability(Experimental) @NotNull public Metric metricBackupToS3Bytes()
      (experimental) Metric for the number of bytes delivered to Amazon S3 for backup over the specified time period.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricBackupToS3Bytes in interface IDeliveryStream
    • metricBackupToS3DataFreshness

      @Stability(Experimental) @NotNull public Metric metricBackupToS3DataFreshness(@Nullable MetricOptions props)
      (experimental) Metric for the age (from getting into Kinesis Data Firehose to now) of the oldest record in Kinesis Data Firehose.

      Any record older than this age has been delivered to the Amazon S3 bucket for backup.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricBackupToS3DataFreshness in interface IDeliveryStream
      Parameters:
      props -
    • metricBackupToS3DataFreshness

      @Stability(Experimental) @NotNull public Metric metricBackupToS3DataFreshness()
      (experimental) Metric for the age (from getting into Kinesis Data Firehose to now) of the oldest record in Kinesis Data Firehose.

      Any record older than this age has been delivered to the Amazon S3 bucket for backup.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricBackupToS3DataFreshness in interface IDeliveryStream
    • metricBackupToS3Records

      @Stability(Experimental) @NotNull public Metric metricBackupToS3Records(@Nullable MetricOptions props)
      (experimental) Metric for the number of records delivered to Amazon S3 for backup over the specified time period.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricBackupToS3Records in interface IDeliveryStream
      Parameters:
      props -
    • metricBackupToS3Records

      @Stability(Experimental) @NotNull public Metric metricBackupToS3Records()
      (experimental) Metric for the number of records delivered to Amazon S3 for backup over the specified time period.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricBackupToS3Records in interface IDeliveryStream
    • metricIncomingBytes

      @Stability(Experimental) @NotNull public Metric metricIncomingBytes(@Nullable MetricOptions props)
      (experimental) Metric for the number of bytes ingested successfully into the delivery stream over the specified time period after throttling.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricIncomingBytes in interface IDeliveryStream
      Parameters:
      props -
    • metricIncomingBytes

      @Stability(Experimental) @NotNull public Metric metricIncomingBytes()
      (experimental) Metric for the number of bytes ingested successfully into the delivery stream over the specified time period after throttling.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricIncomingBytes in interface IDeliveryStream
    • metricIncomingRecords

      @Stability(Experimental) @NotNull public Metric metricIncomingRecords(@Nullable MetricOptions props)
      (experimental) Metric for the number of records ingested successfully into the delivery stream over the specified time period after throttling.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricIncomingRecords in interface IDeliveryStream
      Parameters:
      props -
    • metricIncomingRecords

      @Stability(Experimental) @NotNull public Metric metricIncomingRecords()
      (experimental) Metric for the number of records ingested successfully into the delivery stream over the specified time period after throttling.

      By default, this metric will be calculated as an average over a period of 5 minutes.

      Specified by:
      metricIncomingRecords in interface IDeliveryStream
    • getConnections

      @Stability(Experimental) @NotNull public Connections getConnections()
      (experimental) Network connections between Kinesis Data Firehose and other resources, i.e. Redshift cluster.
      Specified by:
      getConnections in interface IConnectable
    • getDeliveryStreamArn

      @Stability(Experimental) @NotNull public String getDeliveryStreamArn()
      (experimental) The ARN of the delivery stream.
      Specified by:
      getDeliveryStreamArn in interface IDeliveryStream
    • getDeliveryStreamName

      @Stability(Experimental) @NotNull public String getDeliveryStreamName()
      (experimental) The name of the delivery stream.
      Specified by:
      getDeliveryStreamName in interface IDeliveryStream
    • getGrantPrincipal

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