class ApplicationCode
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.Kinesisanalytics.Flink.Alpha.ApplicationCode |
Go | github.com/aws/aws-cdk-go/awscdkkinesisanalyticsflinkalpha/v2#ApplicationCode |
Java | software.amazon.awscdk.services.kinesisanalytics.flink.alpha.ApplicationCode |
Python | aws_cdk.aws_kinesisanalytics_flink_alpha.ApplicationCode |
TypeScript (source) | @aws-cdk/aws-kinesisanalytics-flink-alpha ยป ApplicationCode |
Code configuration providing the location to a Flink application JAR file.
Example
declare const bucket: s3.Bucket;
const flinkApp = new flink.Application(this, 'Application', {
propertyGroups: {
FlinkApplicationProperties: {
inputStreamName: 'my-input-kinesis-stream',
outputStreamName: 'my-output-kinesis-stream',
},
},
// ...
runtime: flink.Runtime.FLINK_1_20,
code: flink.ApplicationCode.fromBucket(bucket, 'my-app.jar'),
});
Initializer
new ApplicationCode()
Methods
Name | Description |
---|---|
bind(scope) | A method to lazily bind asset resources to the parent FlinkApplication. |
static from | Reference code from a local directory containing a Flink JAR file. |
static from | Reference code from an S3 bucket. |
bind(scope)
public bind(scope: Construct): ApplicationCodeConfig
Parameters
- scope
Construct
Returns
A method to lazily bind asset resources to the parent FlinkApplication.
Asset(path, options?)
static frompublic static fromAsset(path: string, options?: AssetOptions): ApplicationCode
Parameters
- path
string
โ - a local directory path. - options
Asset
Options
Returns
Reference code from a local directory containing a Flink JAR file.
Bucket(bucket, fileKey, objectVersion?)
static frompublic static fromBucket(bucket: IBucket, fileKey: string, objectVersion?: string): ApplicationCode
Parameters
- bucket
IBucket
โ - an s3 bucket. - fileKey
string
โ - a key pointing to a Flink JAR file. - objectVersion
string
โ - an optional version string for the provided fileKey.
Returns
Reference code from an S3 bucket.