CfnFunctionConfigurationPropsMixin

class aws_cdk.mixins_preview.aws_appsync.mixins.CfnFunctionConfigurationPropsMixin(props, *, strategy=None)

Bases: Mixin

The AWS::AppSync::FunctionConfiguration resource defines the functions in GraphQL APIs to perform certain operations.

You can use pipeline resolvers to attach functions. For more information, see Pipeline Resolvers in the AWS AppSync Developer Guide . .. epigraph:

When you submit an update, AWS CloudFormation updates resources based on differences between what you submit and the stack's current template. To cause this resource to be updated you must change a property value for this resource in the CloudFormation template. Changing the Amazon S3 file content without changing a property value will not result in an update operation.

See `Update Behaviors of Stack Resources <https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html>`_ in the *AWS CloudFormation User Guide* .
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-appsync-functionconfiguration.html

CloudformationResource:

AWS::AppSync::FunctionConfiguration

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_appsync import mixins as appsync_mixins

cfn_function_configuration_props_mixin = appsync_mixins.CfnFunctionConfigurationPropsMixin(appsync_mixins.CfnFunctionConfigurationMixinProps(
    api_id="apiId",
    code="code",
    code_s3_location="codeS3Location",
    data_source_name="dataSourceName",
    description="description",
    function_version="functionVersion",
    max_batch_size=123,
    name="name",
    request_mapping_template="requestMappingTemplate",
    request_mapping_template_s3_location="requestMappingTemplateS3Location",
    response_mapping_template="responseMappingTemplate",
    response_mapping_template_s3_location="responseMappingTemplateS3Location",
    runtime=appsync_mixins.CfnFunctionConfigurationPropsMixin.AppSyncRuntimeProperty(
        name="name",
        runtime_version="runtimeVersion"
    ),
    sync_config=appsync_mixins.CfnFunctionConfigurationPropsMixin.SyncConfigProperty(
        conflict_detection="conflictDetection",
        conflict_handler="conflictHandler",
        lambda_conflict_handler_config=appsync_mixins.CfnFunctionConfigurationPropsMixin.LambdaConflictHandlerConfigProperty(
            lambda_conflict_handler_arn="lambdaConflictHandlerArn"
        )
    )
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::AppSync::FunctionConfiguration.

Parameters:

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['apiId', 'code', 'codeS3Location', 'dataSourceName', 'description', 'functionVersion', 'maxBatchSize', 'name', 'requestMappingTemplate', 'requestMappingTemplateS3Location', 'responseMappingTemplate', 'responseMappingTemplateS3Location', 'runtime', 'syncConfig']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

AppSyncRuntimeProperty

class CfnFunctionConfigurationPropsMixin.AppSyncRuntimeProperty(*, name=None, runtime_version=None)

Bases: object

Describes a runtime used by an AWS AppSync resolver or AWS AppSync function.

Specifies the name and version of the runtime to use. Note that if a runtime is specified, code must also be specified.

Parameters:
  • name (Optional[str]) – The name of the runtime to use. Currently, the only allowed value is APPSYNC_JS .

  • runtime_version (Optional[str]) – The version of the runtime to use. Currently, the only allowed version is 1.0.0 .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-appsyncruntime.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_appsync import mixins as appsync_mixins

app_sync_runtime_property = appsync_mixins.CfnFunctionConfigurationPropsMixin.AppSyncRuntimeProperty(
    name="name",
    runtime_version="runtimeVersion"
)

Attributes

name

The name of the runtime to use.

Currently, the only allowed value is APPSYNC_JS .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-appsyncruntime.html#cfn-appsync-functionconfiguration-appsyncruntime-name

runtime_version

The version of the runtime to use.

Currently, the only allowed version is 1.0.0 .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-appsyncruntime.html#cfn-appsync-functionconfiguration-appsyncruntime-runtimeversion

LambdaConflictHandlerConfigProperty

class CfnFunctionConfigurationPropsMixin.LambdaConflictHandlerConfigProperty(*, lambda_conflict_handler_arn=None)

Bases: object

The LambdaConflictHandlerConfig object when configuring LAMBDA as the Conflict Handler.

Parameters:

lambda_conflict_handler_arn (Optional[str]) – The Amazon Resource Name (ARN) for the Lambda function to use as the Conflict Handler.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-lambdaconflicthandlerconfig.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_appsync import mixins as appsync_mixins

lambda_conflict_handler_config_property = appsync_mixins.CfnFunctionConfigurationPropsMixin.LambdaConflictHandlerConfigProperty(
    lambda_conflict_handler_arn="lambdaConflictHandlerArn"
)

Attributes

lambda_conflict_handler_arn

The Amazon Resource Name (ARN) for the Lambda function to use as the Conflict Handler.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-lambdaconflicthandlerconfig.html#cfn-appsync-functionconfiguration-lambdaconflicthandlerconfig-lambdaconflicthandlerarn

SyncConfigProperty

class CfnFunctionConfigurationPropsMixin.SyncConfigProperty(*, conflict_detection=None, conflict_handler=None, lambda_conflict_handler_config=None)

Bases: object

Describes a Sync configuration for a resolver.

Specifies which Conflict Detection strategy and Resolution strategy to use when the resolver is invoked.

Parameters:
  • conflict_detection (Optional[str]) – The Conflict Detection strategy to use. - VERSION : Detect conflicts based on object versions for this resolver. - NONE : Do not detect conflicts when invoking this resolver.

  • conflict_handler (Optional[str]) – The Conflict Resolution strategy to perform in the event of a conflict. - OPTIMISTIC_CONCURRENCY : Resolve conflicts by rejecting mutations when versions don’t match the latest version at the server. - AUTOMERGE : Resolve conflicts with the Automerge conflict resolution strategy. - LAMBDA : Resolve conflicts with an AWS Lambda function supplied in the LambdaConflictHandlerConfig .

  • lambda_conflict_handler_config (Union[IResolvable, LambdaConflictHandlerConfigProperty, Dict[str, Any], None]) – The LambdaConflictHandlerConfig when configuring LAMBDA as the Conflict Handler.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-syncconfig.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_appsync import mixins as appsync_mixins

sync_config_property = appsync_mixins.CfnFunctionConfigurationPropsMixin.SyncConfigProperty(
    conflict_detection="conflictDetection",
    conflict_handler="conflictHandler",
    lambda_conflict_handler_config=appsync_mixins.CfnFunctionConfigurationPropsMixin.LambdaConflictHandlerConfigProperty(
        lambda_conflict_handler_arn="lambdaConflictHandlerArn"
    )
)

Attributes

conflict_detection

The Conflict Detection strategy to use.

  • VERSION : Detect conflicts based on object versions for this resolver.

  • NONE : Do not detect conflicts when invoking this resolver.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-syncconfig.html#cfn-appsync-functionconfiguration-syncconfig-conflictdetection

conflict_handler

The Conflict Resolution strategy to perform in the event of a conflict.

  • OPTIMISTIC_CONCURRENCY : Resolve conflicts by rejecting mutations when versions don’t match the latest version at the server.

  • AUTOMERGE : Resolve conflicts with the Automerge conflict resolution strategy.

  • LAMBDA : Resolve conflicts with an AWS Lambda function supplied in the LambdaConflictHandlerConfig .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-syncconfig.html#cfn-appsync-functionconfiguration-syncconfig-conflicthandler

lambda_conflict_handler_config

The LambdaConflictHandlerConfig when configuring LAMBDA as the Conflict Handler.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-functionconfiguration-syncconfig.html#cfn-appsync-functionconfiguration-syncconfig-lambdaconflicthandlerconfig