cdkemrserverlesswithdeltalake

package module
v2.0.14 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 10, 2022 License: Apache-2.0 Imports: 13 Imported by: 0

README

cdk-emrserverless-with-delta-lake

high level architecture

This constrcut builds an EMR studio, a cluster template for the EMR Studio, and an EMR Serverless application. 2 S3 buckets will be created, one is for the EMR Studio workspace and the other one is for EMR Serverless applications. Besides, the VPC and the subnets for the EMR Studio will be tagged {"Key": "for-use-with-amazon-emr-managed-policies", "Value": "true"} via a custom resource. This is necessary for the service role of EMR Studio. This construct is for analysts, data engineers, and anyone who wants to know how to process Delta Lake data with EMR serverless. cfn designer They build the construct via cdkv2 and build a serverless job within the EMR application generated by the construct via AWS CLI within few minutes. After the EMR serverless job is finished, they can then check the processed result done by the EMR serverless job on an EMR notebook through the cluster template. app history

TOC

Requirements

  1. Your current identity has the AdministratorAccess power.

  2. An IAM user named Administrator with the AdministratorAccess power.

    • This is related to the Portfolio of AWS Service Catalog created by the construct, which is required for EMR cluster tempaltes.
    • You can choose whatsoever identity you wish to associate with the Product in the Porfolio for creating an EMR cluster via cluster tempalte. Check serviceCatalogProps in the EmrServerless construct for detail, otherwise, the IAM user mentioned above will be chosen to set up with the Product.

Before deployment

You might want to execute the following command.

PROFILE_NAME="scott.hsieh"
# If you only have one credentials on your local machine, just ignore `--profile`, buddy.
cdk bootstrap aws://${AWS_ACCOUNT_ID}/${AWS_REGION} --profile ${PROFILE_NAME}

Minimal content for deployment

#!/usr/bin/env node
import * as cdk from 'aws-cdk-lib';
import { Construct } from 'constructs';
import { EmrServerless } from 'cdk-emrserverless-with-delta-lake';

class TypescriptStack extends cdk.Stack {
  constructor(scope: Construct, id: string, props?: cdk.StackProps) {
    super(scope, id, props);
    new EmrServerless(this, 'EmrServerless');
  }
}

const app = new cdk.App();
new TypescriptStack(app, 'TypescriptStack', {
  stackName: 'emr-studio',
  env: {
    region: process.env.CDK_DEFAULT_REGION,
    account: process.env.CDK_DEFAULT_ACCOUNT,
  },
});

After deployment

Promise me, darling, make advantage on the CloudFormation outputs. All you need is copy-paste, copy-paste, copy-paste, life should be always that easy. cfn outputs

  1. Define the following environment variables on your current session.

    export PROFILE_NAME="${YOUR_PROFILE_NAME}"
    export JOB_ROLE_ARN="${copy-paste-thank-you}"
    export APPLICATION_ID="${copy-paste-thank-you}"
    export SERVERLESS_BUCKET_NAME="${copy-paste-thank-you}"
    export DELTA_LAKE_SCRIPT_NAME="delta-lake-demo"
    
  2. Copy partial NYC-taxi data into the EMR Serverless bucket.

    aws s3 cp s3://nyc-tlc/trip\ data/ s3://${SERVERLESS_BUCKET_NAME}/nyc-taxi/ --exclude "*" --include "yellow_tripdata_2021-*.parquet" --recursive --profile ${PROFILE_NAME}
    
  3. Create a Python script for processing Delta Lake

    touch ${DELTA_LAKE_SCRIPT_NAME}.py
    cat << EOF > ${DELTA_LAKE_SCRIPT_NAME}.py
    from pyspark.sql import SparkSession
    import uuid
    
    if __name__ == "__main__":
        """
            Delta Lake with EMR Serverless, take NYC taxi as example.
        """
        spark = SparkSession \\
            .builder \\
            .config("spark.sql.extensions", "io.delta.sql.DeltaSparkSessionExtension") \\
            .config("spark.sql.catalog.spark_catalog", "org.apache.spark.sql.delta.catalog.DeltaCatalog") \\
            .enableHiveSupport() \\
            .appName("Delta-Lake-OSS") \\
            .getOrCreate()
    
        url = "s3://${SERVERLESS_BUCKET_NAME}/emr-serverless-spark/delta-lake/output/1.2.1/%s/" % str(
            uuid.uuid4())
    
        # creates a Delta table and outputs to target S3 bucket
        spark.range(5).write.format("delta").save(url)
    
        # reads a Delta table and outputs to target S3 bucket
        spark.read.format("delta").load(url).show()
    
        # The source for the second Delta table.
        base = spark.read.parquet(
            "s3://${SERVERLESS_BUCKET_NAME}/nyc-taxi/*.parquet")
    
        # The sceond Delta table, oh ya.
        base.write.format("delta") \\
            .mode("overwrite") \\
            .save("s3://${SERVERLESS_BUCKET_NAME}/emr-serverless-spark/delta-lake/nyx-tlc-2021")
        spark.stop()
    EOF
    
  4. Upload the script and required jars into the serverless bucket

    # upload script
    aws s3 cp delta-lake-demo.py s3://${SERVERLESS_BUCKET_NAME}/scripts/${DELTA_LAKE_SCRIPT_NAME}.py --profile ${PROFILE_NAME}
    # download jars and upload them
    DELTA_VERSION="1.2.0"
    DELTA_LAKE_CORE="delta-core_2.12-${DELTA_VERSION}.jar"
    DELTA_LAKE_STORAGE="delta-storage-${DELTA_VERSION}.jar"
    curl https://repo1.maven.org/maven2/io/delta/delta-core_2.12/${DELTA_VERSION}/${DELTA_LAKE_CORE} --output ${DELTA_LAKE_CORE}
    curl https://repo1.maven.org/maven2/io/delta/delta-storage/${DELTA_VERSION}/${DELTA_LAKE_STORAGE} --output ${DELTA_LAKE_STORAGE}
    aws s3 mv ${DELTA_LAKE_CORE} s3://${SERVERLESS_BUCKET_NAME}/jars/${${DELTA_LAKE_CORE}} --profile ${PROFILE_NAME}
    aws s3 mv ${DELTA_LAKE_STORAGE} s3://${SERVERLESS_BUCKET_NAME}/jars/${DELTA_LAKE_STORAGE} --profile ${PROFILE_NAME}
    

Create an EMR Serverless app

Rememeber, you got so much information to copy and paste from the CloudFormation outputs. cfn outputs

aws emr-serverless start-job-run \
  --application-id ${APPLICATION_ID} \
  --execution-role-arn ${JOB_ROLE_ARN} \
  --name 'shy-shy-first-time' \
  --job-driver '{
        "sparkSubmit": {
            "entryPoint": "s3://'${SERVERLESS_BUCKET_NAME}'/scripts/'${DELTA_LAKE_SCRIPT_NAME}'.py",
            "sparkSubmitParameters": "--conf spark.executor.cores=1 --conf spark.executor.memory=4g --conf spark.driver.cores=1 --conf spark.driver.memory=4g --conf spark.executor.instances=1 --conf spark.jars=s3://'${SERVERLESS_BUCKET_NAME}'/jars/delta-core_2.12-1.2.0.jar,s3://'${SERVERLESS_BUCKET_NAME}'/jars/delta-storage-1.2.0.jar"
        }
    }' \
  --configuration-overrides '{
        "monitoringConfiguration": {
            "s3MonitoringConfiguration": {
                "logUri": "s3://'${SERVERLESS_BUCKET_NAME}'/serverless-log/"
	        }
	    }
	}' \
	--profile ${PROFILE_NAME}

If you execute with success, you should see similar reponse as the following:

{
    "applicationId": "00f1gvklchoqru25",
    "jobRunId": "00f1h0ipd2maem01",
    "arn": "arn:aws:emr-serverless:ap-northeast-1:630778274080:/applications/00f1gvklchoqru25/jobruns/00f1h0ipd2maem01"
}

and got a Delta Lake data under s3://${SERVERLESS_BUCKET_NAME}/emr-serverless-spark/delta-lake/nyx-tlc-2021/. Delta Lake data

Check the executing job

Access the EMR Studio via the URL from the CloudFormation outputs. It should look very similar to the following url: https://es-pilibalapilibala.emrstudio-prod.ap-northeast-1.amazonaws.com, i.e., weird string and region won't be the same as mine.

  1. Enter into the application enter into the app
  2. Enter into the executing job

Check results from an EMR notebook via cluster template

  1. Create a workspace and an EMR cluster via the cluster template on the AWS Console create workspace
  2. Check the results delivered by the EMR serverless application via an EMR notebook.

Fun facts

  1. You can assign multiple jars as a comma-separated list to the spark.jars as the Spark page says for your EMR Serverless job. The UI will complain, you still can start the job. Don't be afraid, just click it like when you were child, facing authority fearlessly. ui bug
  2. To fully delet a stack with the construct, you need to make sure there is no more workspace within the EMR Studio. Aside from that, you also need to remove the associated identity from the Service Catalog (this is a necessary resource for the cluster template).
  3. Version inconsistency on Spark history. Possibly it can be ignored yet still made me wonder why the versions are different. naughty inconsistency
  4. So far, I still haven't figured out how to make the s3a URI work. The s3 URI is fine while the serverless app will complain that it couldn't find proper credentials provider to read the s3a URI.

Future work

  1. Custom resuorce for EMR Serverless
  2. Make the construct more flexible for users
  3. Compare Databricks Runtime and EMR Serverless.

Documentation

Overview

A construct for the quick demo of EMR Serverless.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EmrClusterTemplateStack_IsConstruct

func EmrClusterTemplateStack_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrClusterTemplateStack_IsStack

func EmrClusterTemplateStack_IsStack(x interface{}) *bool

Return whether the given object is a Stack.

We do attribute detection since we can't reliably use 'instanceof'.

func EmrClusterTemplateStack_Of

func EmrClusterTemplateStack_Of(construct constructs.IConstruct) awscdk.Stack

Looks up the first stack scope in which `construct` is defined.

Fails if there is no stack up the tree.

func EmrServerlessBucket_IsConstruct

func EmrServerlessBucket_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrServerless_IsConstruct

func EmrServerless_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrStudioDeveloperStack_IsConstruct

func EmrStudioDeveloperStack_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrStudioEngineSecurityGroup_IsConstruct

func EmrStudioEngineSecurityGroup_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrStudioServiceRole_IsConstruct

func EmrStudioServiceRole_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrStudioTaggingExpert_IsConstruct

func EmrStudioTaggingExpert_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrStudioWorkspaceSecurityGroup_IsConstruct

func EmrStudioWorkspaceSecurityGroup_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EmrStudio_IsConstruct

func EmrStudio_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func NewEmrClusterTemplateStack_Override

func NewEmrClusterTemplateStack_Override(e EmrClusterTemplateStack, scope constructs.Construct, id *string)

func NewEmrServerlessBucket_Override

func NewEmrServerlessBucket_Override(e EmrServerlessBucket, scope constructs.Construct, name *string, props *EmrServerlessBucketProps)

func NewEmrServerless_Override

func NewEmrServerless_Override(e EmrServerless, scope constructs.Construct, name *string, props *EmrServerlessProps)

func NewEmrStudioDeveloperStack_Override

func NewEmrStudioDeveloperStack_Override(e EmrStudioDeveloperStack, scope constructs.Construct, name *string, props *EmrStudioDeveloperStackProps)

func NewEmrStudioEngineSecurityGroup_Override

func NewEmrStudioEngineSecurityGroup_Override(e EmrStudioEngineSecurityGroup, scope constructs.Construct, name *string, props *EmrStudioEngineSecurityGroupProps)

func NewEmrStudioServiceRole_Override

func NewEmrStudioServiceRole_Override(e EmrStudioServiceRole, scope constructs.Construct, name *string, props *EmrStudioServiceRoleProps)

func NewEmrStudioTaggingExpert_Override

func NewEmrStudioTaggingExpert_Override(e EmrStudioTaggingExpert, scope constructs.Construct, name *string)

func NewEmrStudioWorkspaceSecurityGroup_Override

func NewEmrStudioWorkspaceSecurityGroup_Override(e EmrStudioWorkspaceSecurityGroup, scope constructs.Construct, name *string, props *EmrStudioWorkspaceSecurityGroupProps)

func NewEmrStudio_Override

func NewEmrStudio_Override(e EmrStudio, scope constructs.Construct, name *string, props *EmrStudioProps)

func NewServerlessJobRole_Override

func NewServerlessJobRole_Override(s ServerlessJobRole, scope constructs.Construct, name *string, props *ServerlessJobRoleProps)

func NewWorkSpaceBucket_Override

func NewWorkSpaceBucket_Override(w WorkSpaceBucket, scope constructs.Construct, name *string, props *WorkSpaceBucketProps)

func ServerlessJobRole_IsConstruct

func ServerlessJobRole_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func WorkSpaceBucket_IsConstruct

func WorkSpaceBucket_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

Types

type EmrClusterTemplateStack

type EmrClusterTemplateStack interface {
	awsservicecatalog.ProductStack
	// The AWS account into which this stack will be deployed.
	//
	// This value is resolved according to the following rules:
	//
	// 1. The value provided to `env.account` when the stack is defined. This can
	//     either be a concerete account (e.g. `585695031111`) or the
	//     `Aws.accountId` token.
	// 3. `Aws.accountId`, which represents the CloudFormation intrinsic reference
	//     `{ "Ref": "AWS::AccountId" }` encoded as a string token.
	//
	// Preferably, you should use the return value as an opaque string and not
	// attempt to parse it to implement your logic. If you do, you must first
	// check that it is a concerete value an not an unresolved token. If this
	// value is an unresolved token (`Token.isUnresolved(stack.account)` returns
	// `true`), this implies that the user wishes that this stack will synthesize
	// into a **account-agnostic template**. In this case, your code should either
	// fail (throw an error, emit a synth error using `Annotations.of(construct).addError()`) or
	// implement some other region-agnostic behavior.
	Account() *string
	// The ID of the cloud assembly artifact for this stack.
	ArtifactId() *string
	// Returns the list of AZs that are available in the AWS environment (account/region) associated with this stack.
	//
	// If the stack is environment-agnostic (either account and/or region are
	// tokens), this property will return an array with 2 tokens that will resolve
	// at deploy-time to the first two availability zones returned from CloudFormation's
	// `Fn::GetAZs` intrinsic function.
	//
	// If they are not available in the context, returns a set of dummy values and
	// reports them as missing, and let the CLI resolve them by calling EC2
	// `DescribeAvailabilityZones` on the target environment.
	//
	// To specify a different strategy for selecting availability zones override this method.
	AvailabilityZones() *[]*string
	// Indicates whether the stack requires bundling or not.
	BundlingRequired() *bool
	// Return the stacks this stack depends on.
	Dependencies() *[]awscdk.Stack
	// The environment coordinates in which this stack is deployed.
	//
	// In the form
	// `aws://account/region`. Use `stack.account` and `stack.region` to obtain
	// the specific values, no need to parse.
	//
	// You can use this value to determine if two stacks are targeting the same
	// environment.
	//
	// If either `stack.account` or `stack.region` are not concrete values (e.g.
	// `Aws.account` or `Aws.region`) the special strings `unknown-account` and/or
	// `unknown-region` will be used respectively to indicate this stack is
	// region/account-agnostic.
	Environment() *string
	// Indicates if this is a nested stack, in which case `parentStack` will include a reference to it's parent.
	Nested() *bool
	// If this is a nested stack, returns it's parent stack.
	NestedStackParent() awscdk.Stack
	// If this is a nested stack, this represents its `AWS::CloudFormation::Stack` resource.
	//
	// `undefined` for top-level (non-nested) stacks.
	NestedStackResource() awscdk.CfnResource
	// The tree node.
	Node() constructs.Node
	// Returns the list of notification Amazon Resource Names (ARNs) for the current stack.
	NotificationArns() *[]*string
	// The partition in which this stack is defined.
	Partition() *string
	// The AWS region into which this stack will be deployed (e.g. `us-west-2`).
	//
	// This value is resolved according to the following rules:
	//
	// 1. The value provided to `env.region` when the stack is defined. This can
	//     either be a concerete region (e.g. `us-west-2`) or the `Aws.region`
	//     token.
	// 3. `Aws.region`, which is represents the CloudFormation intrinsic reference
	//     `{ "Ref": "AWS::Region" }` encoded as a string token.
	//
	// Preferably, you should use the return value as an opaque string and not
	// attempt to parse it to implement your logic. If you do, you must first
	// check that it is a concerete value an not an unresolved token. If this
	// value is an unresolved token (`Token.isUnresolved(stack.region)` returns
	// `true`), this implies that the user wishes that this stack will synthesize
	// into a **region-agnostic template**. In this case, your code should either
	// fail (throw an error, emit a synth error using `Annotations.of(construct).addError()`) or
	// implement some other region-agnostic behavior.
	Region() *string
	// The ID of the stack.
	//
	// Example:
	//   // After resolving, looks like
	//   'arn:aws:cloudformation:us-west-2:123456789012:stack/teststack/51af3dc0-da77-11e4-872e-1234567db123'
	//
	StackId() *string
	// The concrete CloudFormation physical stack name.
	//
	// This is either the name defined explicitly in the `stackName` prop or
	// allocated based on the stack's location in the construct tree. Stacks that
	// are directly defined under the app use their construct `id` as their stack
	// name. Stacks that are defined deeper within the tree will use a hashed naming
	// scheme based on the construct path to ensure uniqueness.
	//
	// If you wish to obtain the deploy-time AWS::StackName intrinsic,
	// you can use `Aws.stackName` directly.
	StackName() *string
	// Synthesis method for this stack.
	Synthesizer() awscdk.IStackSynthesizer
	// Tags to be applied to the stack.
	Tags() awscdk.TagManager
	// The name of the CloudFormation template file emitted to the output directory during synthesis.
	//
	// Example value: `MyStack.template.json`
	TemplateFile() *string
	// Options for CloudFormation template (like version, transform, description).
	TemplateOptions() awscdk.ITemplateOptions
	// Whether termination protection is enabled for this stack.
	TerminationProtection() *bool
	// The Amazon domain suffix for the region in which this stack is defined.
	UrlSuffix() *string
	// Add a dependency between this stack and another stack.
	//
	// This can be used to define dependencies between any two stacks within an
	// app, and also supports nested stacks.
	AddDependency(target awscdk.Stack, reason *string)
	// Add a Transform to this stack. A Transform is a macro that AWS CloudFormation uses to process your template.
	//
	// Duplicate values are removed when stack is synthesized.
	//
	// Example:
	//   declare const stack: Stack;
	//
	//   stack.addTransform('AWS::Serverless-2016-10-31')
	//
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/transform-section-structure.html
	//
	AddTransform(transform *string)
	// Returns the naming scheme used to allocate logical IDs.
	//
	// By default, uses
	// the `HashedAddressingScheme` but this method can be overridden to customize
	// this behavior.
	//
	// In order to make sure logical IDs are unique and stable, we hash the resource
	// construct tree path (i.e. toplevel/secondlevel/.../myresource) and add it as
	// a suffix to the path components joined without a separator (CloudFormation
	// IDs only allow alphanumeric characters).
	//
	// The result will be:
	//
	//    <path.join(”)><md5(path.join('/')>
	//      "human"      "hash"
	//
	// If the "human" part of the ID exceeds 240 characters, we simply trim it so
	// the total ID doesn't exceed CloudFormation's 255 character limit.
	//
	// We only take 8 characters from the md5 hash (0.000005 chance of collision).
	//
	// Special cases:
	//
	// - If the path only contains a single component (i.e. it's a top-level
	//    resource), we won't add the hash to it. The hash is not needed for
	//    disamiguation and also, it allows for a more straightforward migration an
	//    existing CloudFormation template to a CDK stack without logical ID changes
	//    (or renames).
	// - For aesthetic reasons, if the last components of the path are the same
	//    (i.e. `L1/L2/Pipeline/Pipeline`), they will be de-duplicated to make the
	//    resulting human portion of the ID more pleasing: `L1L2Pipeline<HASH>`
	//    instead of `L1L2PipelinePipeline<HASH>`
	// - If a component is named "Default" it will be omitted from the path. This
	//    allows refactoring higher level abstractions around constructs without affecting
	//    the IDs of already deployed resources.
	// - If a component is named "Resource" it will be omitted from the user-visible
	//    path, but included in the hash. This reduces visual noise in the human readable
	//    part of the identifier.
	AllocateLogicalId(cfnElement awscdk.CfnElement) *string
	// Create a CloudFormation Export for a value.
	//
	// Returns a string representing the corresponding `Fn.importValue()`
	// expression for this Export. You can control the name for the export by
	// passing the `name` option.
	//
	// If you don't supply a value for `name`, the value you're exporting must be
	// a Resource attribute (for example: `bucket.bucketName`) and it will be
	// given the same name as the automatic cross-stack reference that would be created
	// if you used the attribute in another Stack.
	//
	// One of the uses for this method is to *remove* the relationship between
	// two Stacks established by automatic cross-stack references. It will
	// temporarily ensure that the CloudFormation Export still exists while you
	// remove the reference from the consuming stack. After that, you can remove
	// the resource and the manual export.
	//
	// ## Example
	//
	// Here is how the process works. Let's say there are two stacks,
	// `producerStack` and `consumerStack`, and `producerStack` has a bucket
	// called `bucket`, which is referenced by `consumerStack` (perhaps because
	// an AWS Lambda Function writes into it, or something like that).
	//
	// It is not safe to remove `producerStack.bucket` because as the bucket is being
	// deleted, `consumerStack` might still be using it.
	//
	// Instead, the process takes two deployments:
	//
	// ### Deployment 1: break the relationship
	//
	// - Make sure `consumerStack` no longer references `bucket.bucketName` (maybe the consumer
	//    stack now uses its own bucket, or it writes to an AWS DynamoDB table, or maybe you just
	//    remove the Lambda Function altogether).
	// - In the `ProducerStack` class, call `this.exportValue(this.bucket.bucketName)`. This
	//    will make sure the CloudFormation Export continues to exist while the relationship
	//    between the two stacks is being broken.
	// - Deploy (this will effectively only change the `consumerStack`, but it's safe to deploy both).
	//
	// ### Deployment 2: remove the bucket resource
	//
	// - You are now free to remove the `bucket` resource from `producerStack`.
	// - Don't forget to remove the `exportValue()` call as well.
	// - Deploy again (this time only the `producerStack` will be changed -- the bucket will be deleted).
	ExportValue(exportedValue interface{}, options *awscdk.ExportValueOptions) *string
	// Creates an ARN from components.
	//
	// If `partition`, `region` or `account` are not specified, the stack's
	// partition, region and account will be used.
	//
	// If any component is the empty string, an empty string will be inserted
	// into the generated ARN at the location that component corresponds to.
	//
	// The ARN will be formatted as follows:
	//
	//    arn:{partition}:{service}:{region}:{account}:{resource}{sep}}{resource-name}
	//
	// The required ARN pieces that are omitted will be taken from the stack that
	// the 'scope' is attached to. If all ARN pieces are supplied, the supplied scope
	// can be 'undefined'.
	FormatArn(components *awscdk.ArnComponents) *string
	// Allocates a stack-unique CloudFormation-compatible logical identity for a specific resource.
	//
	// This method is called when a `CfnElement` is created and used to render the
	// initial logical identity of resources. Logical ID renames are applied at
	// this stage.
	//
	// This method uses the protected method `allocateLogicalId` to render the
	// logical ID for an element. To modify the naming scheme, extend the `Stack`
	// class and override this method.
	GetLogicalId(element awscdk.CfnElement) *string
	// Look up a fact value for the given fact for the region of this stack.
	//
	// Will return a definite value only if the region of the current stack is resolved.
	// If not, a lookup map will be added to the stack and the lookup will be done at
	// CDK deployment time.
	//
	// What regions will be included in the lookup map is controlled by the
	// `@aws-cdk/core:target-partitions` context value: it must be set to a list
	// of partitions, and only regions from the given partitions will be included.
	// If no such context key is set, all regions will be included.
	//
	// This function is intended to be used by construct library authors. Application
	// builders can rely on the abstractions offered by construct libraries and do
	// not have to worry about regional facts.
	//
	// If `defaultValue` is not given, it is an error if the fact is unknown for
	// the given region.
	RegionalFact(factName *string, defaultValue *string) *string
	// Rename a generated logical identities.
	//
	// To modify the naming scheme strategy, extend the `Stack` class and
	// override the `allocateLogicalId` method.
	RenameLogicalId(oldId *string, newId *string)
	// Indicate that a context key was expected.
	//
	// Contains instructions which will be emitted into the cloud assembly on how
	// the key should be supplied.
	ReportMissingContextKey(report *cloudassemblyschema.MissingContext)
	// Resolve a tokenized value in the context of the current stack.
	Resolve(obj interface{}) interface{}
	// Splits the provided ARN into its components.
	//
	// Works both if 'arn' is a string like 'arn:aws:s3:::bucket',
	// and a Token representing a dynamic CloudFormation expression
	// (in which case the returned components will also be dynamic CloudFormation expressions,
	// encoded as Tokens).
	SplitArn(arn *string, arnFormat awscdk.ArnFormat) *awscdk.ArnComponents
	// Convert an object, potentially containing tokens, to a JSON string.
	ToJsonString(obj interface{}, space *float64) *string
	// Returns a string representation of this construct.
	ToString() *string
}

Creates a CloudFormation template which will be a Product under a Portfolio of AWS Service Catalog.

This is for creating an EMR cluster via cluster template in the EMR Studio, created by the `EmrServerless` construct, on the AWS Console.

And you don't have control via the `EmrServerless` construct by now. The documentation is for you to grasp the architecture of the `EmrServerless` more easily.

For detail, please refer to [Create AWS CloudFormation templates for Amazon EMR Studio](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio-cluster-templates.html).

```ts

const product = new servicecatalog.CloudFormationProduct(this, 'MyFirstProduct', {
    productName: 'EMR_6.6.0',
    owner: 'scott.hsieh',
    description: 'EMR cluster with 6.6.0 version',
    productVersions: [
      {
        productVersionName: 'v1',
        validateTemplate: true,
        cloudFormationTemplate: servicecatalog.CloudFormationTemplate.fromProductStack(new EmrClusterTemplateStack(this, 'EmrStudio')),
      },

], }); ```.

func NewEmrClusterTemplateStack

func NewEmrClusterTemplateStack(scope constructs.Construct, id *string) EmrClusterTemplateStack

type EmrServerless

type EmrServerless interface {
	constructs.Construct
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

Creates an EMR Studio, an EMR cluster template for the studio, and an EMR Serverless application.

```ts // the quickiest deployment new EmrServerless(this, 'EmrServerless');

// custom deployment references

new EmrServerless(this, 'EmrServerless', {
    vpcId: 'vpc-idididid',
});
new EmrServerless(this, 'EmrServerless', {
    vpcId: 'vpc-idididid',
    subnetIds: ['subnet-eeeee', 'subnet-fffff']
});

const myRole = new iam.Role.fromRoleName('MyRole');

new EmrServerless(this, 'EmrServerless', {
    serviceCatalogProps: {
        role: myRole
    }
});

const myUser = new iam.Role.fromUserName('MyUser');

new EmrServerless(this, 'EmrServerless', {
    vpcId: 'vpc-idididid',
    subnetIds: ['subnet-eeeee', 'subnet-fffff'],
    serviceCatalogProps: {
        user: myUser
    }
});

const myGroup = new iam.Group.fromGroupName('MyGroup');

new EmrServerless(this, 'EmrServerless', {
    serviceCatalogProps: {
        group: myGroup
    }
});

```.

func NewEmrServerless

func NewEmrServerless(scope constructs.Construct, name *string, props *EmrServerlessProps) EmrServerless

type EmrServerlessBucket

type EmrServerlessBucket interface {
	constructs.Construct
	BucketEntity() awss3.Bucket
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

Creates a bucket for EMR Serverless applications.

```ts const emrServerlessBucket = new EmrServerlessBucket(this, 'EmrServerless'); ```.

func NewEmrServerlessBucket

func NewEmrServerlessBucket(scope constructs.Construct, name *string, props *EmrServerlessBucketProps) EmrServerlessBucket

type EmrServerlessBucketProps

type EmrServerlessBucketProps struct {
	// The bucket name for EMR Serverless applications.
	BucketName *string `field:"optional" json:"bucketName" yaml:"bucketName"`
	// Policy to apply when the bucket is removed from this stack.
	RemovalPolicy awscdk.RemovalPolicy `field:"optional" json:"removalPolicy" yaml:"removalPolicy"`
}

Properties for the EMR Serverless bucket.

type EmrServerlessProps

type EmrServerlessProps struct {
	// Options for which kind of identity will be associated with the Product of the Porfolio in AWS Service Catalog for EMR cluster templates.
	//
	// You can choose either an IAM group, IAM role, or IAM user. If you leave it empty, an IAM user named `Administrator` with the `AdministratorAccess` power needs to be created first.
	ServiceCatalogProps *EmrStudioDeveloperStackProps `field:"optional" json:"serviceCatalogProps" yaml:"serviceCatalogProps"`
	// The subnet IDs for the EMR studio.
	//
	// You can select the subnets from the default VPC in your AWS account.
	SubnetIds *[]*string `field:"optional" json:"subnetIds" yaml:"subnetIds"`
	// Used by the EMR Studio.
	VpcId *string `field:"optional" json:"vpcId" yaml:"vpcId"`
}

type EmrStudio

type EmrStudio interface {
	constructs.Construct
	Entity() awsemr.CfnStudio
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

Creates an EMR Studio for EMR Serverless applications.

The Studio is not only for EMR Serverless applications but also for launching an EMR cluster via a cluster template created in this constrcut to check out results transformed by EMR serverless applications.

For what Studio can do further, please refer to [Amazon EMR Studio](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio.html).

```ts const workspaceBucket = new WorkSpaceBucket(this, 'EmrStudio');

const emrStudio = new EmrStudio(this, '', {
    workSpaceBucket: workspaceBucket,
    subnetIds: ['subnet1', 'subnet2', 'subnet3']
});

```.

func NewEmrStudio

func NewEmrStudio(scope constructs.Construct, name *string, props *EmrStudioProps) EmrStudio

type EmrStudioDeveloperStack

type EmrStudioDeveloperStack interface {
	constructs.Construct
	// The tree node.
	Node() constructs.Node
	// The representative of the service catalog for EMR cluster tempaltes.
	Portfolio() awsservicecatalog.Portfolio
	// The representative of the product for demo purpose.
	Product() awsservicecatalog.Product
	// Returns a string representation of this construct.
	ToString() *string
}

Creates a Service Catalog for EMR cluster templates.

For detail, please refer to [Create AWS CloudFormation templates for Amazon EMR Studio](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio-cluster-templates.html).

```ts const emrClusterTemplatePortfolio = new EmrStudioDeveloperStack(this, 'ClusterTempalte'); ```.

func NewEmrStudioDeveloperStack

func NewEmrStudioDeveloperStack(scope constructs.Construct, name *string, props *EmrStudioDeveloperStackProps) EmrStudioDeveloperStack

type EmrStudioDeveloperStackProps

type EmrStudioDeveloperStackProps struct {
	// an IAM group you wish to associate with the Portfolio for EMR cluster template.
	Group awsiam.IGroup `field:"optional" json:"group" yaml:"group"`
	// The provider name in a Service Catalog for EMR cluster templates.
	ProviderName *string `field:"optional" json:"providerName" yaml:"providerName"`
	// an IAM role you wish to associate with the Portfolio for EMR cluster template.
	Role awsiam.IRole `field:"optional" json:"role" yaml:"role"`
	// an IAM user you wish to associate with the Portfolio for EMR cluster template.
	User awsiam.IUser `field:"optional" json:"user" yaml:"user"`
}

Interface for Service Catalog of EMR cluster templates.

type EmrStudioEngineSecurityGroup

type EmrStudioEngineSecurityGroup interface {
	constructs.Construct
	// The representative of the security group as the EMR Studio engine security group.
	Entity() awsec2.SecurityGroup
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

Created an engine security group for EMR notebooks.

For detail, plrease refer to [Engine security group](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio-security-groups.html#emr-studio-security-group-instructions).

```ts const workSpaceSecurityGroup = new EmrStudioWorkspaceSecurityGroup(this, 'Workspace', { vpc: baseVpc }); const engineSecurityGroup = new EmrStudioEngineSecurityGroup(this, 'Engine', { vpc: baseVpc }); workSpaceSecurityGroup.entity.connections.allowTo(engineSecurityGroup.entity, ec2.Port.tcp(18888), 'Allow traffic to any resources in the Engine security group for EMR Studio.'); workSpaceSecurityGroup.entity.addEgressRule(ec2.Peer.anyIpv4(), ec2.Port.tcp(443), 'Allow traffic to the internet to link publicly hosted Git repositories to Workspaces.'); ```.

func NewEmrStudioEngineSecurityGroup

func NewEmrStudioEngineSecurityGroup(scope constructs.Construct, name *string, props *EmrStudioEngineSecurityGroupProps) EmrStudioEngineSecurityGroup

type EmrStudioEngineSecurityGroupProps

type EmrStudioEngineSecurityGroupProps struct {
	// The VPC in which to create the engine security group for EMR Studio.
	Vpc awsec2.IVpc `field:"required" json:"vpc" yaml:"vpc"`
}

Interface for engine security group of EMR Studio.

type EmrStudioProps

type EmrStudioProps struct {
	// The custom construct as the workspace S3 bucket.
	WorkSpaceBucket WorkSpaceBucket `field:"required" json:"workSpaceBucket" yaml:"workSpaceBucket"`
	// Specifies whether the Studio authenticates users using AWS SSO or IAM.
	AuthMode StudioAuthMode `field:"optional" json:"authMode" yaml:"authMode"`
	// A detailed description of the Amazon EMR Studio.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// The ID of the Amazon EMR Studio Engine security group.
	//
	// The Engine security group allows inbound network traffic from the Workspace security group, and it must be in the same VPC specified by VpcId.
	EngineSecurityGroupId *string `field:"optional" json:"engineSecurityGroupId" yaml:"engineSecurityGroupId"`
	// Options for which kind of identity will be associated with the Product of the Porfolio in AWS Service Catalog for EMR cluster templates.
	//
	// You can choose either an IAM group, IAM role, or IAM user. If you leave it empty, an IAM user named `Administrator` with the `AdministratorAccess` power needs to be created first.
	ServiceCatalogProps *EmrStudioDeveloperStackProps `field:"optional" json:"serviceCatalogProps" yaml:"serviceCatalogProps"`
	ServiceRoleArn      *string                       `field:"optional" json:"serviceRoleArn" yaml:"serviceRoleArn"`
	// A name for the service role of an EMR Studio.
	//
	// For valid values, see the RoleName parameter for the CreateRole action in the IAM API Reference.
	//
	// IMPORTANT: If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
	//
	// If you specify a name, you must specify the CAPABILITY_NAMED_IAM value to acknowledge your template's capabilities. For more information, see Acknowledging IAM Resources in AWS CloudFormation Templates.
	ServiceRoleName *string `field:"optional" json:"serviceRoleName" yaml:"serviceRoleName"`
	// A descriptive name for the Amazon EMR Studio.
	StudioName *string `field:"optional" json:"studioName" yaml:"studioName"`
	// The subnet IDs for the EMR studio.
	//
	// You can select the subnets from the default VPC in your AWS account.
	SubnetIds *[]*string `field:"optional" json:"subnetIds" yaml:"subnetIds"`
	// The custom user role for the EMR Studio when authentication is AWS SSO.
	//
	// Currently, if you choose to establish an EMR serverless application where the authentication mechanism used by the EMR Studio is AWS SSO, you need to create a user role by yourself and assign the role arn to this argument if AWS SSO is chosen as authentication for the EMR Studio;.
	UserRoleArn *string `field:"optional" json:"userRoleArn" yaml:"userRoleArn"`
	// Used by the EMR Studio.
	VpcId *string `field:"optional" json:"vpcId" yaml:"vpcId"`
	// The ID of the security group used by the workspace.
	WorkSpaceSecurityGroupId *string `field:"optional" json:"workSpaceSecurityGroupId" yaml:"workSpaceSecurityGroupId"`
}

Options for the EMR Studio, mainly for EMR Serverless applications.

type EmrStudioServiceRole

type EmrStudioServiceRole interface {
	constructs.Construct
	// The tree node.
	Node() constructs.Node
	// The representative of the default service role for EMR Studio.
	RoleEntity() awsiam.Role
	// Returns a string representation of this construct.
	ToString() *string
}

Creates a default service role for an EMR Studio.

For detail, please refer to [Create an EMR Studio service role](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio-service-role.html).

```ts const workSpaceBucket = new WorkSpaceBucket(this, 'WorkSpace');

const emrStudioServiceRole = new EmrStudioServiceRole(this, 'Service', {
      workSpaceBucket: workSpaceBucket
});

```.

func NewEmrStudioServiceRole

func NewEmrStudioServiceRole(scope constructs.Construct, name *string, props *EmrStudioServiceRoleProps) EmrStudioServiceRole

type EmrStudioServiceRoleProps

type EmrStudioServiceRoleProps struct {
	// The custom construct as the workspace S3 bucket.
	WorkSpaceBucket WorkSpaceBucket `field:"required" json:"workSpaceBucket" yaml:"workSpaceBucket"`
	// A name for the service role of an EMR Studio.
	//
	// For valid values, see the RoleName parameter for the CreateRole action in the IAM API Reference.
	//
	// IMPORTANT: If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
	//
	// If you specify a name, you must specify the CAPABILITY_NAMED_IAM value to acknowledge your template's capabilities. For more information, see Acknowledging IAM Resources in AWS CloudFormation Templates.
	RoleName *string `field:"optional" json:"roleName" yaml:"roleName"`
}

Properties for defining the [service role](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio-service-role.html) of an EMR Studio.

type EmrStudioTaggingExpert

type EmrStudioTaggingExpert interface {
	constructs.Construct
	// The repesentative of the Lambda function for the custom resource which can add necessary tag onto the VPC and subnets for the EMR Studio during deployment.
	FunctionEntity() awslambda.Function
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

Creates a Lambda function for the custom resource which can add necessary tag onto the VPC and subnets for the EMR Studio during deployment.

For detail on the tag, please refer to [How to create a service role for EMR Studio](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio-service-role.html#emr-studio-service-role-instructions)

func NewEmrStudioTaggingExpert

func NewEmrStudioTaggingExpert(scope constructs.Construct, name *string) EmrStudioTaggingExpert

type EmrStudioWorkspaceSecurityGroup

type EmrStudioWorkspaceSecurityGroup interface {
	constructs.Construct
	// The representative of the security group as the EMR Studio workspace security group.
	Entity() awsec2.SecurityGroup
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

Created a workspace security group for EMR Studio.

For detail, plrease refer to [Workspace security group](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-studio-security-groups.html#emr-studio-security-group-instructions).

```ts const workSpaceSecurityGroup = new EmrStudioWorkspaceSecurityGroup(this, 'Workspace', { vpc: baseVpc }); const engineSecurityGroup = new EmrStudioEngineSecurityGroup(this, 'Engine', { vpc: baseVpc }); workSpaceSecurityGroup.entity.connections.allowTo(engineSecurityGroup.entity, ec2.Port.tcp(18888), 'Allow traffic to any resources in the Engine security group for EMR Studio.'); workSpaceSecurityGroup.entity.addEgressRule(ec2.Peer.anyIpv4(), ec2.Port.tcp(443), 'Allow traffic to the internet to link publicly hosted Git repositories to Workspaces.'); ```.

func NewEmrStudioWorkspaceSecurityGroup

func NewEmrStudioWorkspaceSecurityGroup(scope constructs.Construct, name *string, props *EmrStudioWorkspaceSecurityGroupProps) EmrStudioWorkspaceSecurityGroup

type EmrStudioWorkspaceSecurityGroupProps

type EmrStudioWorkspaceSecurityGroupProps struct {
	// The VPC in which to create workspace security group for EMR Studio.
	Vpc awsec2.IVpc `field:"required" json:"vpc" yaml:"vpc"`
}

Interface for workspace security group of EMR Studio.

type ServerlessJobRole

type ServerlessJobRole interface {
	constructs.Construct
	// The representative of the execution role for EMR Serverless.
	Entity() awsiam.Role
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

Creates an execution job role for EMR Serverless.

For detail, please refer to [Create a job runtime role](https://docs.aws.amazon.com/emr/latest/EMR-Serverless-UserGuide/getting-started.html#gs-runtime-role).

```ts const emrServerlessBucket = new EmrServerlessBucket(this, 'EmrServerlessStorage'); const emrServerlessJobRole = new ServerlessJobRole(this, 'EmrServerlessJob', {emrServerlessBucket: emrServerlessBucket}); ```.

func NewServerlessJobRole

func NewServerlessJobRole(scope constructs.Construct, name *string, props *ServerlessJobRoleProps) ServerlessJobRole

type ServerlessJobRoleProps

type ServerlessJobRoleProps struct {
	// The EMR Serverless bucket.
	EmrServerlessBucket awss3.Bucket `field:"required" json:"emrServerlessBucket" yaml:"emrServerlessBucket"`
}

Options for the execution job role of EMR Serverless.

type StudioAuthMode

type StudioAuthMode string

What kind of authentication the Studio uses.

const (
	// the Studio authenticates users using AWS SSO.
	StudioAuthMode_AWS_SSO StudioAuthMode = "AWS_SSO"
	// the Studio authenticates users using AWS IAM.
	StudioAuthMode_AWS_IAM StudioAuthMode = "AWS_IAM"
)

type WorkSpaceBucket

type WorkSpaceBucket interface {
	constructs.Construct
	BucketEntity() awss3.Bucket
	// The tree node.
	Node() constructs.Node
	// Returns a string representation of this construct.
	ToString() *string
}

func NewWorkSpaceBucket

func NewWorkSpaceBucket(scope constructs.Construct, name *string, props *WorkSpaceBucketProps) WorkSpaceBucket

type WorkSpaceBucketProps

type WorkSpaceBucketProps struct {
	// The bucket name for the workspace of an EMR Studio.
	BucketName *string `field:"optional" json:"bucketName" yaml:"bucketName"`
	// Policy to apply when the bucket is removed from this stack.
	RemovalPolicy awscdk.RemovalPolicy `field:"optional" json:"removalPolicy" yaml:"removalPolicy"`
}

Directories

Path Synopsis
Package jsii contains the functionaility needed for jsii packages to initialize their dependencies and themselves.
Package jsii contains the functionaility needed for jsii packages to initialize their dependencies and themselves.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL