log_profiles
Creates, updates, deletes, gets or lists a log_profiles
resource.
Overview
Name | log_profiles |
Type | Resource |
Id | azure.monitor.log_profiles |
Fields
- vw_log_profiles
- log_profiles
Name | Datatype | Description |
---|---|---|
id | text | Azure resource Id |
name | text | Azure resource name |
categories | text | field from the properties object |
location | text | Resource location |
locations | text | field from the properties object |
logProfileName | text | field from the properties object |
retention_policy | text | field from the properties object |
service_bus_rule_id | text | field from the properties object |
storage_account_id | text | field from the properties object |
subscriptionId | text | field from the properties object |
system_data | text | field from the properties object |
tags | text | Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater in length than 128 characters and a value no greater in length than 256 characters. |
type | text | Azure resource type |
Name | Datatype | Description |
---|---|---|
id | string | Azure resource Id |
name | string | Azure resource name |
location | string | Resource location |
properties | object | The log profile properties. |
systemData | object | Metadata pertaining to creation and last modification of the resource. |
tags | object | Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater in length than 128 characters and a value no greater in length than 256 characters. |
type | string | Azure resource type |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | logProfileName, subscriptionId | Gets the log profile. |
list | SELECT | subscriptionId | List the log profiles. |
create_or_update | INSERT | logProfileName, subscriptionId, data__properties | Create or update a log profile in Azure Monitoring REST API. |
delete | DELETE | logProfileName, subscriptionId | Deletes the log profile. |
update | UPDATE | logProfileName, subscriptionId | Updates an existing LogProfilesResource. To update other fields use the CreateOrUpdate method. |
SELECT
examples
List the log profiles.
- vw_log_profiles
- log_profiles
SELECT
id,
name,
categories,
location,
locations,
logProfileName,
retention_policy,
service_bus_rule_id,
storage_account_id,
subscriptionId,
system_data,
tags,
type
FROM azure.monitor.vw_log_profiles
WHERE subscriptionId = '{{ subscriptionId }}';
SELECT
id,
name,
location,
properties,
systemData,
tags,
type
FROM azure.monitor.log_profiles
WHERE subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new log_profiles
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.monitor.log_profiles (
logProfileName,
subscriptionId,
data__properties,
location,
tags,
properties
)
SELECT
'{{ logProfileName }}',
'{{ subscriptionId }}',
'{{ data__properties }}',
'{{ location }}',
'{{ tags }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: id
value: string
- name: name
value: string
- name: type
value: string
- name: location
value: string
- name: tags
value: object
- name: systemData
value:
- name: createdBy
value: string
- name: createdByType
value: string
- name: createdAt
value: string
- name: lastModifiedBy
value: string
- name: lastModifiedByType
value: string
- name: lastModifiedAt
value: string
- name: properties
value:
- name: storageAccountId
value: string
- name: serviceBusRuleId
value: string
- name: locations
value:
- string
- name: categories
value:
- string
- name: retentionPolicy
value:
- name: enabled
value: boolean
- name: days
value: integer
UPDATE
example
Updates a log_profiles
resource.
/*+ update */
UPDATE azure.monitor.log_profiles
SET
tags = '{{ tags }}',
properties = '{{ properties }}'
WHERE
logProfileName = '{{ logProfileName }}'
AND subscriptionId = '{{ subscriptionId }}';
DELETE
example
Deletes the specified log_profiles
resource.
/*+ delete */
DELETE FROM azure.monitor.log_profiles
WHERE logProfileName = '{{ logProfileName }}'
AND subscriptionId = '{{ subscriptionId }}';