Show / Hide Table of Contents

Class ResolverProps

Additional property for an AppSync resolver for GraphQL API reference.

Inheritance
object
ResolverProps
Implements
IResolverProps
IExtendedResolverProps
IBaseResolverProps
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.AppSync
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ResolverProps : IResolverProps, IExtendedResolverProps, IBaseResolverProps
Syntax (vb)
Public Class ResolverProps Implements IResolverProps, IExtendedResolverProps, IBaseResolverProps
Remarks

ExampleMetadata: infused

Examples
GraphqlApi api;
            AppsyncFunction appsyncFunction;


            var pipelineResolver = new Resolver(this, "pipeline", new ResolverProps {
                Api = api,
                DataSource = api.AddNoneDataSource("none"),
                TypeName = "typeName",
                FieldName = "fieldName",
                RequestMappingTemplate = MappingTemplate.FromFile("beforeRequest.vtl"),
                PipelineConfig = new [] { appsyncFunction },
                ResponseMappingTemplate = MappingTemplate.FromFile("afterResponse.vtl")
            });

Synopsis

Constructors

ResolverProps()

Additional property for an AppSync resolver for GraphQL API reference.

Properties

Api

The API this resolver is attached to.

CachingConfig

The caching configuration for this resolver.

Code

The function code.

DataSource

The data source this resolver is using.

FieldName

name of the GraphQL field in the given type this resolver is attached to.

MaxBatchSize

The maximum number of elements per batch, when using batch invoke.

MetricsConfig

Whether to enable enhanced metrics Value will be ignored, if enhancedMetricsConfig.resolverLevelMetricsBehavior on AppSync GraphqlApi construct is set to FULL_REQUEST_RESOLVER_METRICS.

PipelineConfig

configuration of the pipeline resolver.

RequestMappingTemplate

The request mapping template for this resolver.

ResponseMappingTemplate

The response mapping template for this resolver.

Runtime

The functions runtime.

TypeName

name of the GraphQL type this resolver is attached to.

Constructors

ResolverProps()

Additional property for an AppSync resolver for GraphQL API reference.

public ResolverProps()
Remarks

ExampleMetadata: infused

Examples
GraphqlApi api;
            AppsyncFunction appsyncFunction;


            var pipelineResolver = new Resolver(this, "pipeline", new ResolverProps {
                Api = api,
                DataSource = api.AddNoneDataSource("none"),
                TypeName = "typeName",
                FieldName = "fieldName",
                RequestMappingTemplate = MappingTemplate.FromFile("beforeRequest.vtl"),
                PipelineConfig = new [] { appsyncFunction },
                ResponseMappingTemplate = MappingTemplate.FromFile("afterResponse.vtl")
            });

Properties

Api

The API this resolver is attached to.

public IGraphqlApi Api { get; set; }
Property Value

IGraphqlApi

Remarks

ExampleMetadata: infused

CachingConfig

The caching configuration for this resolver.

public ICachingConfig? CachingConfig { get; set; }
Property Value

ICachingConfig

Remarks

Default: - No caching configuration

Code

The function code.

public Code? Code { get; set; }
Property Value

Code

Remarks

Default: - no code is used

DataSource

The data source this resolver is using.

public BaseDataSource? DataSource { get; set; }
Property Value

BaseDataSource

Remarks

Default: - No datasource

FieldName

name of the GraphQL field in the given type this resolver is attached to.

public string FieldName { get; set; }
Property Value

string

Remarks

ExampleMetadata: infused

MaxBatchSize

The maximum number of elements per batch, when using batch invoke.

public double? MaxBatchSize { get; set; }
Property Value

double?

Remarks

Default: - No max batch size

MetricsConfig

Whether to enable enhanced metrics Value will be ignored, if enhancedMetricsConfig.resolverLevelMetricsBehavior on AppSync GraphqlApi construct is set to FULL_REQUEST_RESOLVER_METRICS.

public ResolverMetricsConfig? MetricsConfig { get; set; }
Property Value

ResolverMetricsConfig?

Remarks

Default: - no metrics configuration

PipelineConfig

configuration of the pipeline resolver.

public IFunctionConfigurationRef[]? PipelineConfig { get; set; }
Property Value

IFunctionConfigurationRef[]

Remarks

Default: - no pipeline resolver configuration An empty array | undefined sets resolver to be of kind, unit

RequestMappingTemplate

The request mapping template for this resolver.

public MappingTemplate? RequestMappingTemplate { get; set; }
Property Value

MappingTemplate

Remarks

Default: - No mapping template

ResponseMappingTemplate

The response mapping template for this resolver.

public MappingTemplate? ResponseMappingTemplate { get; set; }
Property Value

MappingTemplate

Remarks

Default: - No mapping template

Runtime

The functions runtime.

public FunctionRuntime? Runtime { get; set; }
Property Value

FunctionRuntime

Remarks

Default: - no function runtime, VTL mapping templates used

TypeName

name of the GraphQL type this resolver is attached to.

public string TypeName { get; set; }
Property Value

string

Remarks

ExampleMetadata: infused

Implements

IResolverProps
IExtendedResolverProps
IBaseResolverProps
Back to top Generated by DocFX