class AppSyncBackedDataSource
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.AppSync.AppSyncBackedDataSource |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsappsync#AppSyncBackedDataSource |
Java | software.amazon.awscdk.services.appsync.AppSyncBackedDataSource |
Python | aws_cdk.aws_appsync.AppSyncBackedDataSource |
TypeScript (source) | aws-cdk-lib » aws_appsync » AppSyncBackedDataSource |
Implements
IConstruct, IDependable, IGrantable
Extends
App
Implemented by
App, App, App, App, App, App
Abstract AppSync datasource implementation.
Do not use directly but use subclasses for resource backed datasources
Example
declare const api: appsync.EventApi;
declare const ddbDataSource: appsync.AppSyncDynamoDbDataSource;
declare const ebDataSource: appsync.AppSyncEventBridgeDataSource;
// DynamoDB data source for publish handler
api.addChannelNamespace('ddb-eb-ns', {
code: appsync.Code.fromInline('/* event handler code here.*/'),
publishHandlerConfig: {
dataSource: ddbDataSource,
},
subscribeHandlerConfig: {
dataSource: ebDataSource,
},
});
Initializer
new AppSyncBackedDataSource(scope: Construct, id: string, props: AppSyncBackedDataSourceProps, extended: AppSyncExtendedDataSourceProps)
Parameters
- scope
Construct - id
string - props
AppSync Backed Data Source Props - extended
AppSync Extended Data Source Props
Properties
| Name | Type | Description |
|---|---|---|
| grant | IPrincipal | The principal of the data source to be IGrantable. |
| name | string | The name of the data source. |
| node | Node | The tree node. |
| resource | Cfn | The underlying CFN data source resource. |
grantPrincipal
Type:
IPrincipal
The principal of the data source to be IGrantable.
name
Type:
string
The name of the data source.
node
Type:
Node
The tree node.
resource
Type:
Cfn
The underlying CFN data source resource.
Methods
| Name | Description |
|---|---|
| to | Returns a string representation of this construct. |
toString()
public toString(): string
Returns
string
Returns a string representation of this construct.

.NET
Go
Java
Python
TypeScript (