# DatabaseInsightsMode

The database insights mode.

- Source: [`aws-rds/lib/database-insights-mode.ts`](https://github.com/aws/aws-cdk/blob/v2.274.0/packages/aws-cdk-lib/aws-rds/lib/database-insights-mode.ts#L4)
- Type last changed: v2.179.0 · 18 Feb 2025

## Example

```ts
declare const vpc: ec2.Vpc;
new rds.DatabaseCluster(this, 'Database', {
  engine: rds.DatabaseClusterEngine.AURORA,
  vpc: vpc,
  // If you enable the advanced mode of Database Insights,
  // Performance Insights is enabled and you must set the `performanceInsightRetention` to 465(15 months).
  databaseInsightsMode: rds.DatabaseInsightsMode.ADVANCED,
  performanceInsightRetention: rds.PerformanceInsightRetention.MONTHS_15,
  writer: rds.ClusterInstance.provisioned('Writer', {
    instanceType: ec2.InstanceType.of(ec2.InstanceClass.R7G, ec2.InstanceSize.LARGE),
  }),
});
```

## Members

| Member | Description |
| --- | --- |
| `STANDARD` | Standard mode. |
| `ADVANCED` | Advanced mode. |

## Referenced by

- [`DatabaseCluster`](/v2/docs/aws-cdk-lib.aws_rds.DatabaseCluster).databaseInsightsMode
- [`DatabaseClusterFromSnapshot`](/v2/docs/aws-cdk-lib.aws_rds.DatabaseClusterFromSnapshot).databaseInsightsMode
- [`DatabaseClusterFromSnapshotProps`](/v2/docs/aws-cdk-lib.aws_rds.DatabaseClusterFromSnapshotProps).databaseInsightsMode
- [`DatabaseClusterProps`](/v2/docs/aws-cdk-lib.aws_rds.DatabaseClusterProps).databaseInsightsMode
- [`DatabaseInstanceNewProps`](/v2/docs/aws-cdk-lib.aws_rds.DatabaseInstanceNewProps).databaseInsightsMode
