Try AWS Native preview for resources not in the classic version.
aws.applicationinsights.Application
Explore with Pulumi AI
Try AWS Native preview for resources not in the classic version.
Provides a ApplicationInsights Application resource.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const exampleGroup = new aws.resourcegroups.Group("example", {
name: "example",
resourceQuery: {
query: JSON.stringify({
ResourceTypeFilters: ["AWS::EC2::Instance"],
TagFilters: [{
Key: "Stage",
Values: ["Test"],
}],
}),
},
});
const example = new aws.applicationinsights.Application("example", {resourceGroupName: exampleGroup.name});
import pulumi
import json
import pulumi_aws as aws
example_group = aws.resourcegroups.Group("example",
name="example",
resource_query={
"query": json.dumps({
"ResourceTypeFilters": ["AWS::EC2::Instance"],
"TagFilters": [{
"Key": "Stage",
"Values": ["Test"],
}],
}),
})
example = aws.applicationinsights.Application("example", resource_group_name=example_group.name)
package main
import (
"encoding/json"
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/applicationinsights"
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/resourcegroups"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
tmpJSON0, err := json.Marshal(map[string]interface{}{
"ResourceTypeFilters": []string{
"AWS::EC2::Instance",
},
"TagFilters": []map[string]interface{}{
map[string]interface{}{
"Key": "Stage",
"Values": []string{
"Test",
},
},
},
})
if err != nil {
return err
}
json0 := string(tmpJSON0)
exampleGroup, err := resourcegroups.NewGroup(ctx, "example", &resourcegroups.GroupArgs{
Name: pulumi.String("example"),
ResourceQuery: &resourcegroups.GroupResourceQueryArgs{
Query: pulumi.String(json0),
},
})
if err != nil {
return err
}
_, err = applicationinsights.NewApplication(ctx, "example", &applicationinsights.ApplicationArgs{
ResourceGroupName: exampleGroup.Name,
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using System.Text.Json;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var exampleGroup = new Aws.ResourceGroups.Group("example", new()
{
Name = "example",
ResourceQuery = new Aws.ResourceGroups.Inputs.GroupResourceQueryArgs
{
Query = JsonSerializer.Serialize(new Dictionary<string, object?>
{
["ResourceTypeFilters"] = new[]
{
"AWS::EC2::Instance",
},
["TagFilters"] = new[]
{
new Dictionary<string, object?>
{
["Key"] = "Stage",
["Values"] = new[]
{
"Test",
},
},
},
}),
},
});
var example = new Aws.ApplicationInsights.Application("example", new()
{
ResourceGroupName = exampleGroup.Name,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.resourcegroups.Group;
import com.pulumi.aws.resourcegroups.GroupArgs;
import com.pulumi.aws.resourcegroups.inputs.GroupResourceQueryArgs;
import com.pulumi.aws.applicationinsights.Application;
import com.pulumi.aws.applicationinsights.ApplicationArgs;
import static com.pulumi.codegen.internal.Serialization.*;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleGroup = new Group("exampleGroup", GroupArgs.builder()
.name("example")
.resourceQuery(GroupResourceQueryArgs.builder()
.query(serializeJson(
jsonObject(
jsonProperty("ResourceTypeFilters", jsonArray("AWS::EC2::Instance")),
jsonProperty("TagFilters", jsonArray(jsonObject(
jsonProperty("Key", "Stage"),
jsonProperty("Values", jsonArray("Test"))
)))
)))
.build())
.build());
var example = new Application("example", ApplicationArgs.builder()
.resourceGroupName(exampleGroup.name())
.build());
}
}
resources:
example:
type: aws:applicationinsights:Application
properties:
resourceGroupName: ${exampleGroup.name}
exampleGroup:
type: aws:resourcegroups:Group
name: example
properties:
name: example
resourceQuery:
query:
fn::toJSON:
ResourceTypeFilters:
- AWS::EC2::Instance
TagFilters:
- Key: Stage
Values:
- Test
Create Application Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Application(name: string, args: ApplicationArgs, opts?: CustomResourceOptions);
@overload
def Application(resource_name: str,
args: ApplicationArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Application(resource_name: str,
opts: Optional[ResourceOptions] = None,
resource_group_name: Optional[str] = None,
auto_config_enabled: Optional[bool] = None,
auto_create: Optional[bool] = None,
cwe_monitor_enabled: Optional[bool] = None,
grouping_type: Optional[str] = None,
ops_center_enabled: Optional[bool] = None,
ops_item_sns_topic_arn: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None)
func NewApplication(ctx *Context, name string, args ApplicationArgs, opts ...ResourceOption) (*Application, error)
public Application(string name, ApplicationArgs args, CustomResourceOptions? opts = null)
public Application(String name, ApplicationArgs args)
public Application(String name, ApplicationArgs args, CustomResourceOptions options)
type: aws:applicationinsights:Application
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ApplicationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ApplicationArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ApplicationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ApplicationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ApplicationArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var awsApplicationResource = new Aws.ApplicationInsights.Application("awsApplicationResource", new()
{
ResourceGroupName = "string",
AutoConfigEnabled = false,
AutoCreate = false,
CweMonitorEnabled = false,
GroupingType = "string",
OpsCenterEnabled = false,
OpsItemSnsTopicArn = "string",
Tags =
{
{ "string", "string" },
},
});
example, err := applicationinsights.NewApplication(ctx, "awsApplicationResource", &applicationinsights.ApplicationArgs{
ResourceGroupName: pulumi.String("string"),
AutoConfigEnabled: pulumi.Bool(false),
AutoCreate: pulumi.Bool(false),
CweMonitorEnabled: pulumi.Bool(false),
GroupingType: pulumi.String("string"),
OpsCenterEnabled: pulumi.Bool(false),
OpsItemSnsTopicArn: pulumi.String("string"),
Tags: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var awsApplicationResource = new Application("awsApplicationResource", ApplicationArgs.builder()
.resourceGroupName("string")
.autoConfigEnabled(false)
.autoCreate(false)
.cweMonitorEnabled(false)
.groupingType("string")
.opsCenterEnabled(false)
.opsItemSnsTopicArn("string")
.tags(Map.of("string", "string"))
.build());
aws_application_resource = aws.applicationinsights.Application("awsApplicationResource",
resource_group_name="string",
auto_config_enabled=False,
auto_create=False,
cwe_monitor_enabled=False,
grouping_type="string",
ops_center_enabled=False,
ops_item_sns_topic_arn="string",
tags={
"string": "string",
})
const awsApplicationResource = new aws.applicationinsights.Application("awsApplicationResource", {
resourceGroupName: "string",
autoConfigEnabled: false,
autoCreate: false,
cweMonitorEnabled: false,
groupingType: "string",
opsCenterEnabled: false,
opsItemSnsTopicArn: "string",
tags: {
string: "string",
},
});
type: aws:applicationinsights:Application
properties:
autoConfigEnabled: false
autoCreate: false
cweMonitorEnabled: false
groupingType: string
opsCenterEnabled: false
opsItemSnsTopicArn: string
resourceGroupName: string
tags:
string: string
Application Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The Application resource accepts the following input properties:
- Resource
Group stringName Name of the resource group.
The following arguments are optional:
- Auto
Config boolEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- Auto
Create bool - Configures all of the resources in the resource group by applying the recommended configurations.
- Cwe
Monitor boolEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- Grouping
Type 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
. - Ops
Center boolEnabled - When set to
true
, creates opsItems for any problems detected on an application. - Ops
Item stringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- Dictionary<string, string>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- Resource
Group stringName Name of the resource group.
The following arguments are optional:
- Auto
Config boolEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- Auto
Create bool - Configures all of the resources in the resource group by applying the recommended configurations.
- Cwe
Monitor boolEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- Grouping
Type 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
. - Ops
Center boolEnabled - When set to
true
, creates opsItems for any problems detected on an application. - Ops
Item stringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- map[string]string
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- resource
Group StringName Name of the resource group.
The following arguments are optional:
- auto
Config BooleanEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto
Create Boolean - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe
Monitor BooleanEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping
Type 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
. - ops
Center BooleanEnabled - When set to
true
, creates opsItems for any problems detected on an application. - ops
Item StringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- Map<String,String>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- resource
Group stringName Name of the resource group.
The following arguments are optional:
- auto
Config booleanEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto
Create boolean - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe
Monitor booleanEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping
Type 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
. - ops
Center booleanEnabled - When set to
true
, creates opsItems for any problems detected on an application. - ops
Item stringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- {[key: string]: string}
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- resource_
group_ strname Name of the resource group.
The following arguments are optional:
- auto_
config_ boolenabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto_
create bool - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe_
monitor_ boolenabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping_
type str - 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
. - ops_
center_ boolenabled - When set to
true
, creates opsItems for any problems detected on an application. - ops_
item_ strsns_ topic_ arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- Mapping[str, str]
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- resource
Group StringName Name of the resource group.
The following arguments are optional:
- auto
Config BooleanEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto
Create Boolean - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe
Monitor BooleanEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping
Type 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
. - ops
Center BooleanEnabled - When set to
true
, creates opsItems for any problems detected on an application. - ops
Item StringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- Map<String>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Outputs
All input properties are implicitly available as output properties. Additionally, the Application resource produces the following output properties:
Look up Existing Application Resource
Get an existing Application resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: ApplicationState, opts?: CustomResourceOptions): Application
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
arn: Optional[str] = None,
auto_config_enabled: Optional[bool] = None,
auto_create: Optional[bool] = None,
cwe_monitor_enabled: Optional[bool] = None,
grouping_type: Optional[str] = None,
ops_center_enabled: Optional[bool] = None,
ops_item_sns_topic_arn: Optional[str] = None,
resource_group_name: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
tags_all: Optional[Mapping[str, str]] = None) -> Application
func GetApplication(ctx *Context, name string, id IDInput, state *ApplicationState, opts ...ResourceOption) (*Application, error)
public static Application Get(string name, Input<string> id, ApplicationState? state, CustomResourceOptions? opts = null)
public static Application get(String name, Output<String> id, ApplicationState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Arn string
- ARN of the Application.
- Auto
Config boolEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- Auto
Create bool - Configures all of the resources in the resource group by applying the recommended configurations.
- Cwe
Monitor boolEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- Grouping
Type 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
. - Ops
Center boolEnabled - When set to
true
, creates opsItems for any problems detected on an application. - Ops
Item stringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- Resource
Group stringName Name of the resource group.
The following arguments are optional:
- Dictionary<string, string>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Dictionary<string, string>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- Arn string
- ARN of the Application.
- Auto
Config boolEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- Auto
Create bool - Configures all of the resources in the resource group by applying the recommended configurations.
- Cwe
Monitor boolEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- Grouping
Type 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
. - Ops
Center boolEnabled - When set to
true
, creates opsItems for any problems detected on an application. - Ops
Item stringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- Resource
Group stringName Name of the resource group.
The following arguments are optional:
- map[string]string
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - map[string]string
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn String
- ARN of the Application.
- auto
Config BooleanEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto
Create Boolean - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe
Monitor BooleanEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping
Type 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
. - ops
Center BooleanEnabled - When set to
true
, creates opsItems for any problems detected on an application. - ops
Item StringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- resource
Group StringName Name of the resource group.
The following arguments are optional:
- Map<String,String>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Map<String,String>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn string
- ARN of the Application.
- auto
Config booleanEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto
Create boolean - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe
Monitor booleanEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping
Type 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
. - ops
Center booleanEnabled - When set to
true
, creates opsItems for any problems detected on an application. - ops
Item stringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- resource
Group stringName Name of the resource group.
The following arguments are optional:
- {[key: string]: string}
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - {[key: string]: string}
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn str
- ARN of the Application.
- auto_
config_ boolenabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto_
create bool - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe_
monitor_ boolenabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping_
type str - 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
. - ops_
center_ boolenabled - When set to
true
, creates opsItems for any problems detected on an application. - ops_
item_ strsns_ topic_ arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- resource_
group_ strname Name of the resource group.
The following arguments are optional:
- Mapping[str, str]
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Mapping[str, str]
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn String
- ARN of the Application.
- auto
Config BooleanEnabled - Indicates whether Application Insights automatically configures unmonitored resources in the resource group.
- auto
Create Boolean - Configures all of the resources in the resource group by applying the recommended configurations.
- cwe
Monitor BooleanEnabled - Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as instance terminated, failed deployment, and others.
- grouping
Type 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
. - ops
Center BooleanEnabled - When set to
true
, creates opsItems for any problems detected on an application. - ops
Item StringSns Topic Arn - SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.
- resource
Group StringName Name of the resource group.
The following arguments are optional:
- Map<String>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Map<String>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
Import
Using pulumi import
, import ApplicationInsights Applications using the resource_group_name
. For example:
$ pulumi import aws:applicationinsights/application:Application some some-application
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.
Try AWS Native preview for resources not in the classic version.