Class CfnDataSourceProps
Properties for defining a CfnDataSource
.
Inheritance
Implements
Namespace: Amazon.CDK.AWS.AppSync
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnDataSourceProps : Object, ICfnDataSourceProps
Syntax (vb)
Public Class CfnDataSourceProps
Inherits Object
Implements ICfnDataSourceProps
Remarks
See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-appsync-datasource.html
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.AppSync;
var cfnDataSourceProps = new CfnDataSourceProps {
ApiId = "apiId",
Name = "name",
Type = "type",
// the properties below are optional
Description = "description",
DynamoDbConfig = new DynamoDBConfigProperty {
AwsRegion = "awsRegion",
TableName = "tableName",
// the properties below are optional
DeltaSyncConfig = new DeltaSyncConfigProperty {
BaseTableTtl = "baseTableTtl",
DeltaSyncTableName = "deltaSyncTableName",
DeltaSyncTableTtl = "deltaSyncTableTtl"
},
UseCallerCredentials = false,
Versioned = false
},
ElasticsearchConfig = new ElasticsearchConfigProperty {
AwsRegion = "awsRegion",
Endpoint = "endpoint"
},
EventBridgeConfig = new EventBridgeConfigProperty {
EventBusArn = "eventBusArn"
},
HttpConfig = new HttpConfigProperty {
Endpoint = "endpoint",
// the properties below are optional
AuthorizationConfig = new AuthorizationConfigProperty {
AuthorizationType = "authorizationType",
// the properties below are optional
AwsIamConfig = new AwsIamConfigProperty {
SigningRegion = "signingRegion",
SigningServiceName = "signingServiceName"
}
}
},
LambdaConfig = new LambdaConfigProperty {
LambdaFunctionArn = "lambdaFunctionArn"
},
MetricsConfig = "metricsConfig",
OpenSearchServiceConfig = new OpenSearchServiceConfigProperty {
AwsRegion = "awsRegion",
Endpoint = "endpoint"
},
RelationalDatabaseConfig = new RelationalDatabaseConfigProperty {
RelationalDatabaseSourceType = "relationalDatabaseSourceType",
// the properties below are optional
RdsHttpEndpointConfig = new RdsHttpEndpointConfigProperty {
AwsRegion = "awsRegion",
AwsSecretStoreArn = "awsSecretStoreArn",
DbClusterIdentifier = "dbClusterIdentifier",
// the properties below are optional
DatabaseName = "databaseName",
Schema = "schema"
}
},
ServiceRoleArn = "serviceRoleArn"
};
Synopsis
Constructors
CfnDataSourceProps() |
Properties
ApiId | Unique AWS AppSync GraphQL API identifier where this data source will be created. |
Description | The description of the data source. |
DynamoDbConfig | AWS Region and TableName for an Amazon DynamoDB table in your account. |
ElasticsearchConfig | AWS Region and Endpoints for an Amazon OpenSearch Service domain in your account. |
EventBridgeConfig | An EventBridge configuration that contains a valid ARN of an event bus. |
HttpConfig | Endpoints for an HTTP data source. |
LambdaConfig | An ARN of a Lambda function in valid ARN format. |
MetricsConfig | Enables or disables enhanced data source metrics for specified data sources. |
Name | Friendly name for you to identify your AppSync data source after creation. |
OpenSearchServiceConfig | AWS Region and Endpoints for an Amazon OpenSearch Service domain in your account. |
RelationalDatabaseConfig | Relational Database configuration of the relational database data source. |
ServiceRoleArn | The AWS Identity and Access Management service role ARN for the data source. |
Type | The type of the data source. |
Constructors
CfnDataSourceProps()
public CfnDataSourceProps()
Properties
ApiId
Unique AWS AppSync GraphQL API identifier where this data source will be created.
public string ApiId { get; set; }
Property Value
System.String
Remarks
Description
The description of the data source.
public string Description { get; set; }
Property Value
System.String
Remarks
DynamoDbConfig
AWS Region and TableName for an Amazon DynamoDB table in your account.
public object DynamoDbConfig { get; set; }
Property Value
System.Object
Remarks
ElasticsearchConfig
AWS Region and Endpoints for an Amazon OpenSearch Service domain in your account.
public object ElasticsearchConfig { get; set; }
Property Value
System.Object
Remarks
As of September 2021, Amazon Elasticsearch Service is Amazon OpenSearch Service . This property is deprecated. For new data sources, use OpenSearchServiceConfig to specify an OpenSearch Service data source.
EventBridgeConfig
An EventBridge configuration that contains a valid ARN of an event bus.
public object EventBridgeConfig { get; set; }
Property Value
System.Object
Remarks
HttpConfig
Endpoints for an HTTP data source.
public object HttpConfig { get; set; }
Property Value
System.Object
Remarks
LambdaConfig
An ARN of a Lambda function in valid ARN format.
public object LambdaConfig { get; set; }
Property Value
System.Object
Remarks
This can be the ARN of a Lambda function that exists in the current account or in another account.
MetricsConfig
Enables or disables enhanced data source metrics for specified data sources.
public string MetricsConfig { get; set; }
Property Value
System.String
Remarks
Note that MetricsConfig
won't be used unless the dataSourceLevelMetricsBehavior
value is set to PER_DATA_SOURCE_METRICS
. If the dataSourceLevelMetricsBehavior
is set to FULL_REQUEST_DATA_SOURCE_METRICS
instead, MetricsConfig
will be ignored. However, you can still set its value.
MetricsConfig
can be ENABLED
or DISABLED
.
Name
Friendly name for you to identify your AppSync data source after creation.
public string Name { get; set; }
Property Value
System.String
Remarks
OpenSearchServiceConfig
AWS Region and Endpoints for an Amazon OpenSearch Service domain in your account.
public object OpenSearchServiceConfig { get; set; }
Property Value
System.Object
Remarks
RelationalDatabaseConfig
Relational Database configuration of the relational database data source.
public object RelationalDatabaseConfig { get; set; }
Property Value
System.Object
Remarks
ServiceRoleArn
The AWS Identity and Access Management service role ARN for the data source.
public string ServiceRoleArn { get; set; }
Property Value
System.String
Remarks
The system assumes this role when accessing the data source.
Required if Type
is specified as AWS_LAMBDA
, AMAZON_DYNAMODB
, AMAZON_ELASTICSEARCH
, AMAZON_EVENTBRIDGE
, or AMAZON_OPENSEARCH_SERVICE
.
Type
The type of the data source.
public string Type { get; set; }
Property Value
System.String