components
Creates, updates, deletes, gets or lists a components
resource.
Overview
Name | components |
Type | Resource |
Id | azure.application_insights.components |
Fields
The following fields are returned by SELECT
queries:
- get
- list_by_resource_group
- list
An Application Insights Component definition.
Name | Datatype | Description |
---|---|---|
id | string | Azure resource Id |
name | string | Azure resource name |
etag | string | Resource etag |
kind | string | The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone. |
location | string | Resource location |
properties | object | Properties that define an Application Insights component resource. |
tags |
| Resource tags |
type | string | Azure resource type |
A list containing 0 or more Application Insights component definitions.
Name | Datatype | Description |
---|---|---|
id | string | Azure resource Id |
name | string | Azure resource name |
etag | string | Resource etag |
kind | string | The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone. |
location | string | Resource location |
properties | object | Properties that define an Application Insights component resource. |
tags |
| Resource tags |
type | string | Azure resource type |
A list containing 0 or more Application Insights component definitions.
Name | Datatype | Description |
---|---|---|
id | string | Azure resource Id |
name | string | Azure resource name |
etag | string | Resource etag |
kind | string | The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone. |
location | string | Resource location |
properties | object | Properties that define an Application Insights component resource. |
tags |
| Resource tags |
type | string | Azure resource type |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | resourceGroupName , subscriptionId , resourceName | Returns an Application Insights component. | |
list_by_resource_group | select | resourceGroupName , subscriptionId | Gets a list of Application Insights components within a resource group. | |
list | select | subscriptionId | Gets a list of all Application Insights components within a subscription. | |
create_or_update | insert | resourceGroupName , subscriptionId , resourceName , data__kind | Creates (or updates) an Application Insights component. Note: You cannot specify a different value for InstrumentationKey nor AppId in the Put operation. | |
delete | delete | resourceGroupName , subscriptionId , resourceName | Deletes an Application Insights component. | |
update_tags | exec | resourceGroupName , subscriptionId , resourceName | Updates an existing component's tags. To update other fields use the CreateOrUpdate method. | |
purge | exec | resourceGroupName , subscriptionId , resourceName , table , filters | Purges data in an Application Insights component by a set of user-defined filters. In order to manage system resources, purge requests are throttled at 50 requests per hour. You should batch the execution of purge requests by sending a single command whose predicate includes all user identities that require purging. Use the in operator to specify multiple identities. You should run the query prior to using for a purge request to verify that the results are expected. Note: this operation is intended for Classic resources, for workspace-based Application Insights resource please run purge operation (directly on the workspace)(https://docs.microsoft.com/en-us/rest/api/loganalytics/workspace-purge/purge) , scoped to specific resource id. |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
resourceGroupName | string | The name of the resource group. The name is case insensitive. |
resourceName | string | The name of the Application Insights component resource. |
subscriptionId | string (uuid) | The ID of the target subscription. The value must be an UUID. |
SELECT
examples
- get
- list_by_resource_group
- list
Returns an Application Insights component.
SELECT
id,
name,
etag,
kind,
location,
properties,
tags,
type
FROM azure.application_insights.components
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
AND resourceName = '{{ resourceName }}' -- required
;
Gets a list of Application Insights components within a resource group.
SELECT
id,
name,
etag,
kind,
location,
properties,
tags,
type
FROM azure.application_insights.components
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
Gets a list of all Application Insights components within a subscription.
SELECT
id,
name,
etag,
kind,
location,
properties,
tags,
type
FROM azure.application_insights.components
WHERE subscriptionId = '{{ subscriptionId }}' -- required
;
INSERT
examples
- create_or_update
- Manifest
Creates (or updates) an Application Insights component. Note: You cannot specify a different value for InstrumentationKey nor AppId in the Put operation.
INSERT INTO azure.application_insights.components (
data__kind,
data__etag,
data__properties,
data__location,
data__tags,
resourceGroupName,
subscriptionId,
resourceName
)
SELECT
'{{ kind }}' /* required */,
'{{ etag }}',
'{{ properties }}',
'{{ location }}',
'{{ tags }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ resourceName }}'
RETURNING
id,
name,
etag,
kind,
location,
properties,
tags,
type
;
# Description fields are for documentation purposes
- name: components
props:
- name: resourceGroupName
value: string
description: Required parameter for the components resource.
- name: subscriptionId
value: string (uuid)
description: Required parameter for the components resource.
- name: resourceName
value: string
description: Required parameter for the components resource.
- name: kind
value: string
description: |
The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone.
- name: etag
value: string
description: |
Resource etag
- name: properties
value: object
description: |
Properties that define an Application Insights component resource.
- name: location
value: string
description: |
Resource location
- name: tags
value: string
description: |
Resource tags
DELETE
examples
- delete
Deletes an Application Insights component.
DELETE FROM azure.application_insights.components
WHERE resourceGroupName = '{{ resourceGroupName }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
AND resourceName = '{{ resourceName }}' --required
;
Lifecycle Methods
- update_tags
- purge
Updates an existing component's tags. To update other fields use the CreateOrUpdate method.
EXEC azure.application_insights.components.update_tags
@resourceGroupName='{{ resourceGroupName }}' --required,
@subscriptionId='{{ subscriptionId }}' --required,
@resourceName='{{ resourceName }}' --required
@@json=
'{
"tags": "{{ tags }}"
}'
;
Purges data in an Application Insights component by a set of user-defined filters.
In order to manage system resources, purge requests are throttled at 50 requests per hour. You should batch the execution of purge requests by sending a single command whose predicate includes all user identities that require purging. Use the in operator to specify multiple identities. You should run the query prior to using for a purge request to verify that the results are expected.
Note: this operation is intended for Classic resources, for workspace-based Application Insights resource please run purge operation (directly on the workspace)(https://docs.microsoft.com/en-us/rest/api/loganalytics/workspace-purge/purge) , scoped to specific resource id.
EXEC azure.application_insights.components.purge
@resourceGroupName='{{ resourceGroupName }}' --required,
@subscriptionId='{{ subscriptionId }}' --required,
@resourceName='{{ resourceName }}' --required
@@json=
'{
"table": "{{ table }}",
"filters": "{{ filters }}"
}'
;