UNPKG

@pulumi/aws

Version:

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

206 lines • 8.99 kB
"use strict"; // *** WARNING: this file was generated by pulumi-language-nodejs. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.AnalyticsApplication = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Provides a Kinesis Analytics Application resource. Kinesis Analytics is a managed service that * allows processing and analyzing streaming data using standard SQL. * * For more details, see the [Amazon Kinesis Analytics Documentation](https://docs.aws.amazon.com/kinesisanalytics/latest/dev/what-is.html). * * !> **WARNING:** _This resource is deprecated and will be removed in a future version._ [Effective January 27, 2026](https://aws.amazon.com/blogs/big-data/migrate-from-amazon-kinesis-data-analytics-for-sql-to-amazon-managed-service-for-apache-flink-and-amazon-managed-service-for-apache-flink-studio/), AWS will [no longer support](https://docs.aws.amazon.com/kinesisanalytics/latest/dev/discontinuation.html) Amazon Kinesis Data Analytics for SQL. Use the `aws.kinesisanalyticsv2.Application` resource instead to manage Amazon Kinesis Data Analytics for Apache Flink applications. AWS provides guidance for migrating from [Amazon Kinesis Data Analytics for SQL Applications to Amazon Managed Service for Apache Flink Studio](https://aws.amazon.com/blogs/big-data/migrate-from-amazon-kinesis-data-analytics-for-sql-applications-to-amazon-managed-service-for-apache-flink-studio/) including [examples](https://docs.aws.amazon.com/kinesisanalytics/latest/dev/migrating-to-kda-studio-overview.html). * * > **Note:** To manage Amazon Kinesis Data Analytics for Apache Flink applications, use the `aws.kinesisanalyticsv2.Application` resource. * * ## Example Usage * * ### Kinesis Stream Input * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const testStream = new aws.kinesis.Stream("test_stream", { * name: "kinesis-test", * shardCount: 1, * }); * const testApplication = new aws.kinesis.AnalyticsApplication("test_application", { * name: "kinesis-analytics-application-test", * inputs: { * namePrefix: "test_prefix", * kinesisStream: { * resourceArn: testStream.arn, * roleArn: test.arn, * }, * parallelism: { * count: 1, * }, * schema: { * recordColumns: [{ * mapping: "$.test", * name: "test", * sqlType: "VARCHAR(8)", * }], * recordEncoding: "UTF-8", * recordFormat: { * mappingParameters: { * json: { * recordRowPath: "$", * }, * }, * }, * }, * }, * }); * ``` * * ### Starting An Application * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.cloudwatch.LogGroup("example", {name: "analytics"}); * const exampleLogStream = new aws.cloudwatch.LogStream("example", { * name: "example-kinesis-application", * logGroupName: example.name, * }); * const exampleStream = new aws.kinesis.Stream("example", { * name: "example-kinesis-stream", * shardCount: 1, * }); * const exampleFirehoseDeliveryStream = new aws.kinesis.FirehoseDeliveryStream("example", { * name: "example-kinesis-delivery-stream", * destination: "extended_s3", * extendedS3Configuration: { * bucketArn: exampleAwsS3Bucket.arn, * roleArn: exampleAwsIamRole.arn, * }, * }); * const test = new aws.kinesis.AnalyticsApplication("test", { * name: "example-application", * cloudwatchLoggingOptions: { * logStreamArn: exampleLogStream.arn, * roleArn: exampleAwsIamRole.arn, * }, * inputs: { * namePrefix: "example_prefix", * schema: { * recordColumns: [{ * name: "COLUMN_1", * sqlType: "INTEGER", * }], * recordFormat: { * mappingParameters: { * csv: { * recordColumnDelimiter: ",", * recordRowDelimiter: "|", * }, * }, * }, * }, * kinesisStream: { * resourceArn: exampleStream.arn, * roleArn: exampleAwsIamRole.arn, * }, * startingPositionConfigurations: [{ * startingPosition: "NOW", * }], * }, * outputs: [{ * name: "OUTPUT_1", * schema: { * recordFormatType: "CSV", * }, * kinesisFirehose: { * resourceArn: exampleFirehoseDeliveryStream.arn, * roleArn: exampleAwsIamRole.arn, * }, * }], * startApplication: true, * }); * ``` * * ## Import * * Using `pulumi import`, import Kinesis Analytics Application using ARN. For example: * * ```sh * $ pulumi import aws:kinesis/analyticsApplication:AnalyticsApplication example arn:aws:kinesisanalytics:us-west-2:1234567890:application/example * ``` */ class AnalyticsApplication extends pulumi.CustomResource { /** * Get an existing AnalyticsApplication resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name, id, state, opts) { return new AnalyticsApplication(name, state, { ...opts, id: id }); } /** * Returns true if the given object is an instance of AnalyticsApplication. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj) { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === AnalyticsApplication.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["arn"] = state?.arn; resourceInputs["cloudwatchLoggingOptions"] = state?.cloudwatchLoggingOptions; resourceInputs["code"] = state?.code; resourceInputs["createTimestamp"] = state?.createTimestamp; resourceInputs["description"] = state?.description; resourceInputs["inputs"] = state?.inputs; resourceInputs["lastUpdateTimestamp"] = state?.lastUpdateTimestamp; resourceInputs["name"] = state?.name; resourceInputs["outputs"] = state?.outputs; resourceInputs["referenceDataSources"] = state?.referenceDataSources; resourceInputs["region"] = state?.region; resourceInputs["startApplication"] = state?.startApplication; resourceInputs["status"] = state?.status; resourceInputs["tags"] = state?.tags; resourceInputs["tagsAll"] = state?.tagsAll; resourceInputs["version"] = state?.version; } else { const args = argsOrState; resourceInputs["cloudwatchLoggingOptions"] = args?.cloudwatchLoggingOptions; resourceInputs["code"] = args?.code; resourceInputs["description"] = args?.description; resourceInputs["inputs"] = args?.inputs; resourceInputs["name"] = args?.name; resourceInputs["outputs"] = args?.outputs; resourceInputs["referenceDataSources"] = args?.referenceDataSources; resourceInputs["region"] = args?.region; resourceInputs["startApplication"] = args?.startApplication; resourceInputs["tags"] = args?.tags; resourceInputs["arn"] = undefined /*out*/; resourceInputs["createTimestamp"] = undefined /*out*/; resourceInputs["lastUpdateTimestamp"] = undefined /*out*/; resourceInputs["status"] = undefined /*out*/; resourceInputs["tagsAll"] = undefined /*out*/; resourceInputs["version"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(AnalyticsApplication.__pulumiType, name, resourceInputs, opts); } } exports.AnalyticsApplication = AnalyticsApplication; /** @internal */ AnalyticsApplication.__pulumiType = 'aws:kinesis/analyticsApplication:AnalyticsApplication'; //# sourceMappingURL=analyticsApplication.js.map