in cdk/lib/construct/storage.ts [10:26]
constructor(scope: Construct, id: string) {
super(scope, id);
const connectionIdTable = new dynamo.Table(this, "ConnectionIdTable", {
partitionKey: { name: "connectionId", type: dynamo.AttributeType.STRING },
timeToLiveAttribute: "removedAt",
billingMode: dynamo.BillingMode.PAY_PER_REQUEST,
removalPolicy: RemovalPolicy.DESTROY,
});
connectionIdTable.addGlobalSecondaryIndex({
partitionKey: { name: "userId", type: dynamo.AttributeType.STRING },
indexName: "userIdIndex",
});
this.connectionIdTable = connectionIdTable;
}