annotations
Creates, updates, deletes, gets or lists a annotations
resource.
Overview
Name | annotations |
Type | Resource |
Id | azure.application_insights.annotations |
Fields
Name | Datatype | Description |
---|---|---|
AnnotationName | string | Name of annotation |
Category | string | Category of annotation, free form |
EventTime | string | Time when event occurred |
Id | string | Unique Id for annotation |
Properties | string | Serialized JSON object for detailed properties |
RelatedAnnotation | string | Related parent annotation if any |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | annotationId, resourceGroupName, resourceName, subscriptionId | Get the annotation for given id. |
list | SELECT | end, resourceGroupName, resourceName, start, subscriptionId | Gets the list of annotations for a component for given time range |
create | INSERT | resourceGroupName, resourceName, subscriptionId | Create an Annotation of an Application Insights component. |
delete | DELETE | annotationId, resourceGroupName, resourceName, subscriptionId | Delete an Annotation of an Application Insights component. |
SELECT
examples
Gets the list of annotations for a component for given time range
SELECT
AnnotationName,
Category,
EventTime,
Id,
Properties,
RelatedAnnotation
FROM azure.application_insights.annotations
WHERE end = '{{ end }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND resourceName = '{{ resourceName }}'
AND start = '{{ start }}'
AND subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new annotations
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.application_insights.annotations (
resourceGroupName,
resourceName,
subscriptionId,
AnnotationName,
Category,
EventTime,
Id,
Properties,
RelatedAnnotation
)
SELECT
'{{ resourceGroupName }}',
'{{ resourceName }}',
'{{ subscriptionId }}',
'{{ AnnotationName }}',
'{{ Category }}',
'{{ EventTime }}',
'{{ Id }}',
'{{ Properties }}',
'{{ RelatedAnnotation }}'
;
- name: your_resource_model_name
props:
- name: AnnotationName
value: string
- name: Category
value: string
- name: EventTime
value: string
- name: Id
value: string
- name: Properties
value: string
- name: RelatedAnnotation
value: string
DELETE
example
Deletes the specified annotations
resource.
/*+ delete */
DELETE FROM azure.application_insights.annotations
WHERE annotationId = '{{ annotationId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND resourceName = '{{ resourceName }}'
AND subscriptionId = '{{ subscriptionId }}';