# CfnApplicationProps

Properties for defining a `CfnApplication`.

Extends: CfnApplicationProps
Used as props by: CfnApplication

- Source: Generated code
- Type last changed: v2.168.0 · 20 Nov 2024

## Example

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_applicationinsights as applicationinsights } from 'aws-cdk-lib';
const cfnApplicationProps: applicationinsights.CfnApplicationProps = {
  resourceGroupName: 'resourceGroupName',

  // the properties below are optional
  attachMissingPermission: false,
  autoConfigurationEnabled: false,
  componentMonitoringSettings: [{
    componentConfigurationMode: 'componentConfigurationMode',
    tier: 'tier',

    // the properties below are optional
    componentArn: 'componentArn',
    componentName: 'componentName',
    customComponentConfiguration: {
      configurationDetails: {
        alarmMetrics: [{
          alarmMetricName: 'alarmMetricName',
        }],
        alarms: [{
          alarmName: 'alarmName',

          // the properties below are optional
          severity: 'severity',
        }],
        haClusterPrometheusExporter: {
          prometheusPort: 'prometheusPort',
        },
        hanaPrometheusExporter: {
          agreeToInstallHanadbClient: false,
          hanaPort: 'hanaPort',
          hanaSecretName: 'hanaSecretName',
          hanasid: 'hanasid',

          // the properties below are optional
          prometheusPort: 'prometheusPort',
        },
        jmxPrometheusExporter: {
          hostPort: 'hostPort',
          jmxurl: 'jmxurl',
          prometheusPort: 'prometheusPort',
        },
        logs: [{
          logType: 'logType',

          // the properties below are optional
          encoding: 'encoding',
          logGroupName: 'logGroupName',
          logPath: 'logPath',
          patternSet: 'patternSet',
        }],
        netWeaverPrometheusExporter: {
          instanceNumbers: ['instanceNumbers'],
          sapsid: 'sapsid',

          // the properties below are optional
          prometheusPort: 'prometheusPort',
        },
        processes: [{
          alarmMetrics: [{
            alarmMetricName: 'alarmMetricName',
          }],
          processName: 'processName',
        }],
        sqlServerPrometheusExporter: {
          prometheusPort: 'prometheusPort',
          sqlSecretName: 'sqlSecretName',
        },
        windowsEvents: [{
          eventLevels: ['eventLevels'],
          eventName: 'eventName',
          logGroupName: 'logGroupName',

          // the properties below are optional
          patternSet: 'patternSet',
        }],
      },
      subComponentTypeConfigurations: [{
        subComponentConfigurationDetails: {
          alarmMetrics: [{
            alarmMetricName: 'alarmMetricName',
          }],
          logs: [{
            logType: 'logType',

            // the properties below are optional
            encoding: 'encoding',
            logGroupName: 'logGroupName',
            logPath: 'logPath',
            patternSet: 'patternSet',
          }],
          processes: [{
            alarmMetrics: [{
              alarmMetricName: 'alarmMetricName',
            }],
            processName: 'processName',
          }],
          windowsEvents: [{
            eventLevels: ['eventLevels'],
            eventName: 'eventName',
            logGroupName: 'logGroupName',

            // the properties below are optional
            patternSet: 'patternSet',
          }],
        },
        subComponentType: 'subComponentType',
      }],
    },
    defaultOverwriteComponentConfiguration: {
      configurationDetails: {
        alarmMetrics: [{
          alarmMetricName: 'alarmMetricName',
        }],
        alarms: [{
          alarmName: 'alarmName',

          // the properties below are optional
          severity: 'severity',
        }],
        haClusterPrometheusExporter: {
          prometheusPort: 'prometheusPort',
        },
        hanaPrometheusExporter: {
          agreeToInstallHanadbClient: false,
          hanaPort: 'hanaPort',
          hanaSecretName: 'hanaSecretName',
          hanasid: 'hanasid',

          // the properties below are optional
          prometheusPort: 'prometheusPort',
        },
        jmxPrometheusExporter: {
          hostPort: 'hostPort',
          jmxurl: 'jmxurl',
          prometheusPort: 'prometheusPort',
        },
        logs: [{
          logType: 'logType',

          // the properties below are optional
          encoding: 'encoding',
          logGroupName: 'logGroupName',
          logPath: 'logPath',
          patternSet: 'patternSet',
        }],
        netWeaverPrometheusExporter: {
          instanceNumbers: ['instanceNumbers'],
          sapsid: 'sapsid',

          // the properties below are optional
          prometheusPort: 'prometheusPort',
        },
        processes: [{
          alarmMetrics: [{
            alarmMetricName: 'alarmMetricName',
          }],
          processName: 'processName',
        }],
        sqlServerPrometheusExporter: {
          prometheusPort: 'prometheusPort',
          sqlSecretName: 'sqlSecretName',
        },
        windowsEvents: [{
          eventLevels: ['eventLevels'],
          eventName: 'eventName',
          logGroupName: 'logGroupName',

          // the properties below are optional
          patternSet: 'patternSet',
        }],
      },
      subComponentTypeConfigurations: [{
        subComponentConfigurationDetails: {
          alarmMetrics: [{
            alarmMetricName: 'alarmMetricName',
          }],
          logs: [{
            logType: 'logType',

            // the properties below are optional
            encoding: 'encoding',
            logGroupName: 'logGroupName',
            logPath: 'logPath',
            patternSet: 'patternSet',
          }],
          processes: [{
            alarmMetrics: [{
              alarmMetricName: 'alarmMetricName',
            }],
            processName: 'processName',
          }],
          windowsEvents: [{
            eventLevels: ['eventLevels'],
            eventName: 'eventName',
            logGroupName: 'logGroupName',

            // the properties below are optional
            patternSet: 'patternSet',
          }],
        },
        subComponentType: 'subComponentType',
      }],
    },
  }],
  customComponents: [{
    componentName: 'componentName',
    resourceList: ['resourceList'],
  }],
  cweMonitorEnabled: false,
  groupingType: 'groupingType',
  logPatternSets: [{
    logPatterns: [{
      pattern: 'pattern',
      patternName: 'patternName',
      rank: 123,
    }],
    patternSetName: 'patternSetName',
  }],
  opsCenterEnabled: false,
  opsItemSnsTopicArn: 'opsItemSnsTopicArn',
  snsNotificationArn: 'snsNotificationArn',
  tags: [{
    key: 'key',
    value: 'value',
  }],
};
```

## Properties

- `attachMissingPermission`: boolean | [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) — If set to true, the managed policies for SSM and CW will be attached to the instance roles if they are missing.

- `autoConfigurationEnabled`: boolean | [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) — If set to `true` , the application components will be configured with the monitoring configuration recommended by Application Insights.

- `componentMonitoringSettings`: [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnApplication.ComponentMonitoringSettingProperty](/cdk/api/v2/docs/aws-cdk-lib.aws_applicationinsights.CfnApplication.ComponentMonitoringSettingProperty.html)[] — The monitoring settings of the components.

  Not required to set up default monitoring for all components. To set up default monitoring for all components, set `AutoConfigurationEnabled` to `true` .

- `customComponents`: [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnApplication.CustomComponentProperty](/cdk/api/v2/docs/aws-cdk-lib.aws_applicationinsights.CfnApplication.CustomComponentProperty.html)[] — Describes a custom component by grouping similar standalone instances to monitor.

- `cweMonitorEnabled`: boolean | [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) — Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as `instance terminated` , `failed deployment` , and others.

- `groupingType`: string — Application Insights can create applications based on a resource group or on an account.

  To create an account-based application using all of the resources in the account, set this parameter to `ACCOUNT_BASED` .

- `logPatternSets`: [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnApplication.LogPatternSetProperty](/cdk/api/v2/docs/aws-cdk-lib.aws_applicationinsights.CfnApplication.LogPatternSetProperty.html)[] — The log pattern sets.

- `opsCenterEnabled`: boolean | [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) — Indicates whether Application Insights will create OpsItems for any problem that is detected by Application Insights for an application.

- `opsItemSnsTopicArn`: string — The SNS topic provided to Application Insights that is associated with the created OpsItems to receive SNS notifications for opsItem updates.

- `resourceGroupName`: string (required) — The name of the resource group used for the application.

- `snsNotificationArn`: string — The SNS topic ARN that is associated with SNS notifications for updates or issues.

- `tags`: [CfnTag](/cdk/api/v2/docs/aws-cdk-lib.CfnTag.html)[] — An array of `Tags` .
