Skip to main content

clusters

Creates, updates, deletes, gets or lists a clusters resource.

Overview

Nameclusters
TypeResource
Idazure.log_analytics.clusters

Fields

NameDatatypeDescription
associated_workspacestextfield from the properties object
billing_typetextfield from the properties object
capacity_reservation_propertiestextfield from the properties object
clusterNametextfield from the properties object
cluster_idtextfield from the properties object
created_datetextfield from the properties object
identitytextManaged service identity (system assigned and/or user assigned identities)
is_availability_zones_enabledtextfield from the properties object
is_double_encryption_enabledtextfield from the properties object
key_vault_propertiestextfield from the properties object
last_modified_datetextfield from the properties object
locationtextThe geo-location where the resource lives
provisioning_statetextfield from the properties object
resourceGroupNametextfield from the properties object
skutextThe cluster sku definition.
subscriptionIdtextfield from the properties object
tagstextResource tags.

Methods

NameAccessible byRequired ParamsDescription
getSELECTclusterName, resourceGroupName, subscriptionIdGets a Log Analytics cluster instance.
listSELECTsubscriptionIdGets the Log Analytics clusters in a subscription.
list_by_resource_groupSELECTresourceGroupName, subscriptionIdGets Log Analytics clusters in a resource group.
create_or_updateINSERTclusterName, resourceGroupName, subscriptionIdCreate or update a Log Analytics cluster.
deleteDELETEclusterName, resourceGroupName, subscriptionIdDeletes a cluster instance.
updateUPDATEclusterName, resourceGroupName, subscriptionIdUpdates a Log Analytics cluster.

SELECT examples

Gets the Log Analytics clusters in a subscription.

SELECT
associated_workspaces,
billing_type,
capacity_reservation_properties,
clusterName,
cluster_id,
created_date,
identity,
is_availability_zones_enabled,
is_double_encryption_enabled,
key_vault_properties,
last_modified_date,
location,
provisioning_state,
resourceGroupName,
sku,
subscriptionId,
tags
FROM azure.log_analytics.vw_clusters
WHERE subscriptionId = '{{ subscriptionId }}';

INSERT example

Use the following StackQL query and manifest file to create a new clusters resource.

/*+ create */
INSERT INTO azure.log_analytics.clusters (
clusterName,
resourceGroupName,
subscriptionId,
identity,
sku,
properties,
tags,
location
)
SELECT
'{{ clusterName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ identity }}',
'{{ sku }}',
'{{ properties }}',
'{{ tags }}',
'{{ location }}'
;

UPDATE example

Updates a clusters resource.

/*+ update */
UPDATE azure.log_analytics.clusters
SET
properties = '{{ properties }}',
identity = '{{ identity }}',
sku = '{{ sku }}',
tags = '{{ tags }}'
WHERE
clusterName = '{{ clusterName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified clusters resource.

/*+ delete */
DELETE FROM azure.log_analytics.clusters
WHERE clusterName = '{{ clusterName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';