cassandra_clusters
Creates, updates, deletes, gets or lists a cassandra_clusters
resource.
Overview
Name | cassandra_clusters |
Type | Resource |
Id | azure.cosmos_db.cassandra_clusters |
Fields
The following fields are returned by SELECT
queries:
- get
- list_by_resource_group
- list_by_subscription
The properties of the managed Cassandra cluster were retrieved successfully.
Name | Datatype | Description |
---|---|---|
id | string | The unique resource identifier of the ARM resource. |
name | string | The name of the ARM resource. |
identity | object | Identity for the resource. |
location | string | The location of the resource group to which the resource belongs. |
properties | object | Properties of a managed Cassandra cluster. |
tags | object | Tags are 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 than 128 characters and value no greater than 256 characters. For example, the default experience for a template type is set with "defaultExperience": "Cassandra". Current "defaultExperience" values also include "Table", "Graph", "DocumentDB", and "MongoDB". |
type | string | The type of Azure resource. |
Successfully retrieved the list of managed Cassandra clusters.
Name | Datatype | Description |
---|---|---|
id | string | The unique resource identifier of the ARM resource. |
name | string | The name of the ARM resource. |
identity | object | Identity for the resource. |
location | string | The location of the resource group to which the resource belongs. |
properties | object | Properties of a managed Cassandra cluster. |
tags | object | Tags are 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 than 128 characters and value no greater than 256 characters. For example, the default experience for a template type is set with "defaultExperience": "Cassandra". Current "defaultExperience" values also include "Table", "Graph", "DocumentDB", and "MongoDB". |
type | string | The type of Azure resource. |
Successfully retrieved the list of managed Cassandra clusters.
Name | Datatype | Description |
---|---|---|
id | string | The unique resource identifier of the ARM resource. |
name | string | The name of the ARM resource. |
identity | object | Identity for the resource. |
location | string | The location of the resource group to which the resource belongs. |
properties | object | Properties of a managed Cassandra cluster. |
tags | object | Tags are 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 than 128 characters and value no greater than 256 characters. For example, the default experience for a template type is set with "defaultExperience": "Cassandra". Current "defaultExperience" values also include "Table", "Graph", "DocumentDB", and "MongoDB". |
type | string | The type of Azure resource. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | subscriptionId , resourceGroupName , clusterName | Get the properties of a managed Cassandra cluster. | |
list_by_resource_group | select | subscriptionId , resourceGroupName | List all managed Cassandra clusters in this resource group. | |
list_by_subscription | select | subscriptionId | List all managed Cassandra clusters in this subscription. | |
create_update | insert | subscriptionId , resourceGroupName , clusterName | Create or update a managed Cassandra cluster. When updating, you must specify all writable properties. To update only some properties, use PATCH. | |
update | update | subscriptionId , resourceGroupName , clusterName | Updates some of the properties of a managed Cassandra cluster. | |
delete | delete | subscriptionId , resourceGroupName , clusterName | Deletes a managed Cassandra cluster. | |
invoke_command | exec | subscriptionId , resourceGroupName , clusterName , command , host | Invoke a command like nodetool for cassandra maintenance | |
invoke_command_async | exec | subscriptionId , resourceGroupName , clusterName , command , host | Invoke a command like nodetool for cassandra maintenance asynchronously | |
deallocate | exec | subscriptionId , resourceGroupName , clusterName | x-ms-force-deallocate | Deallocate the Managed Cassandra Cluster and Associated Data Centers. Deallocation will deallocate the host virtual machine of this cluster, and reserved the data disk. This won't do anything on an already deallocated cluster. Use Start to restart the cluster. |
start | exec | subscriptionId , resourceGroupName , clusterName | Start the Managed Cassandra Cluster and Associated Data Centers. Start will start the host virtual machine of this cluster with reserved data disk. This won't do anything on an already running cluster. Use Deallocate to deallocate the cluster. | |
status | exec | subscriptionId , resourceGroupName , clusterName | Gets the CPU, memory, and disk usage statistics for each Cassandra node in a cluster. |
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 |
---|---|---|
clusterName | string | Managed Cassandra cluster name. |
resourceGroupName | string | The name of the resource group. The name is case insensitive. |
subscriptionId | string | The ID of the target subscription. |
x-ms-force-deallocate | string | Force to deallocate a cluster of Cluster Type Production. Force to deallocate a cluster of Cluster Type Production might cause data loss |
SELECT
examples
- get
- list_by_resource_group
- list_by_subscription
Get the properties of a managed Cassandra cluster.
SELECT
id,
name,
identity,
location,
properties,
tags,
type
FROM azure.cosmos_db.cassandra_clusters
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND clusterName = '{{ clusterName }}' -- required
;
List all managed Cassandra clusters in this resource group.
SELECT
id,
name,
identity,
location,
properties,
tags,
type
FROM azure.cosmos_db.cassandra_clusters
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
;
List all managed Cassandra clusters in this subscription.
SELECT
id,
name,
identity,
location,
properties,
tags,
type
FROM azure.cosmos_db.cassandra_clusters
WHERE subscriptionId = '{{ subscriptionId }}' -- required
;
INSERT
examples
- create_update
- Manifest
Create or update a managed Cassandra cluster. When updating, you must specify all writable properties. To update only some properties, use PATCH.
INSERT INTO azure.cosmos_db.cassandra_clusters (
data__location,
data__tags,
data__identity,
data__properties,
subscriptionId,
resourceGroupName,
clusterName
)
SELECT
'{{ location }}',
'{{ tags }}',
'{{ identity }}',
'{{ properties }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ clusterName }}'
RETURNING
id,
name,
identity,
location,
properties,
tags,
type
;
# Description fields are for documentation purposes
- name: cassandra_clusters
props:
- name: subscriptionId
value: string
description: Required parameter for the cassandra_clusters resource.
- name: resourceGroupName
value: string
description: Required parameter for the cassandra_clusters resource.
- name: clusterName
value: string
description: Required parameter for the cassandra_clusters resource.
- name: location
value: string
description: |
The location of the resource group to which the resource belongs.
- name: tags
value: object
description: |
Tags are 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 than 128 characters and value no greater than 256 characters. For example, the default experience for a template type is set with "defaultExperience": "Cassandra". Current "defaultExperience" values also include "Table", "Graph", "DocumentDB", and "MongoDB".
- name: identity
value: object
description: |
Identity for the resource.
- name: properties
value: object
description: |
Properties of a managed Cassandra cluster.
UPDATE
examples
- update
Updates some of the properties of a managed Cassandra cluster.
UPDATE azure.cosmos_db.cassandra_clusters
SET
data__location = '{{ location }}',
data__tags = '{{ tags }}',
data__identity = '{{ identity }}',
data__properties = '{{ properties }}'
WHERE
subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND clusterName = '{{ clusterName }}' --required
RETURNING
id,
name,
identity,
location,
properties,
tags,
type;
DELETE
examples
- delete
Deletes a managed Cassandra cluster.
DELETE FROM azure.cosmos_db.cassandra_clusters
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND clusterName = '{{ clusterName }}' --required
;
Lifecycle Methods
- invoke_command
- invoke_command_async
- deallocate
- start
- status
Invoke a command like nodetool for cassandra maintenance
EXEC azure.cosmos_db.cassandra_clusters.invoke_command
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@clusterName='{{ clusterName }}' --required
@@json=
'{
"command": "{{ command }}",
"arguments": "{{ arguments }}",
"host": "{{ host }}",
"cassandra-stop-start": {{ cassandra-stop-start }},
"readWrite": {{ readWrite }}
}'
;
Invoke a command like nodetool for cassandra maintenance asynchronously
EXEC azure.cosmos_db.cassandra_clusters.invoke_command_async
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@clusterName='{{ clusterName }}' --required
@@json=
'{
"command": "{{ command }}",
"arguments": "{{ arguments }}",
"host": "{{ host }}",
"cassandra-stop-start": {{ cassandra-stop-start }},
"readWrite": {{ readWrite }}
}'
;
Deallocate the Managed Cassandra Cluster and Associated Data Centers. Deallocation will deallocate the host virtual machine of this cluster, and reserved the data disk. This won't do anything on an already deallocated cluster. Use Start to restart the cluster.
EXEC azure.cosmos_db.cassandra_clusters.deallocate
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@clusterName='{{ clusterName }}' --required,
@x-ms-force-deallocate='{{ x-ms-force-deallocate }}'
;
Start the Managed Cassandra Cluster and Associated Data Centers. Start will start the host virtual machine of this cluster with reserved data disk. This won't do anything on an already running cluster. Use Deallocate to deallocate the cluster.
EXEC azure.cosmos_db.cassandra_clusters.start
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@clusterName='{{ clusterName }}' --required
;
Gets the CPU, memory, and disk usage statistics for each Cassandra node in a cluster.
EXEC azure.cosmos_db.cassandra_clusters.status
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@clusterName='{{ clusterName }}' --required
;