nodes
Creates, updates, deletes, gets or lists a nodes resource.
Overview
| Name | nodes |
| Type | Resource |
| Id | aws.medialive.nodes |
Fields
The following fields are returned by SELECT queries:
- describe_node
- list_nodes
| Name | Datatype | Description |
|---|---|---|
arn | string | Placeholder documentation for __string |
channel_placement_groups | array | Placeholder documentation for __listOf__string |
cluster_id | string | Placeholder documentation for __string |
connection_state | string | The current connection state of the Node. (CONNECTED, DISCONNECTED) |
id | string | Placeholder documentation for __string |
instance_arn | string | Placeholder documentation for __string |
name | string | Placeholder documentation for __string |
node_interface_mappings | array | Placeholder documentation for __listOfNodeInterfaceMapping |
role | string | Used in CreateNodeRequest, CreateNodeRegistrationScriptRequest, DescribeNodeResult, DescribeNodeSummary, UpdateNodeRequest. (BACKUP, ACTIVE) |
sdi_source_mappings | array | An array of SDI source mappings. Each mapping connects one logical SdiSource to the physical SDI card and port that the physical SDI source uses. |
state | string | The current state of the Node. (CREATED, REGISTERING, READY_TO_ACTIVATE, REGISTRATION_FAILED, ACTIVATION_FAILED, ACTIVE, READY, IN_USE, DEREGISTERING, DRAINING, DEREGISTRATION_FAILED, DEREGISTERED) |
| Name | Datatype | Description |
|---|---|---|
arn | string | Placeholder documentation for __string |
channel_placement_groups | array | Placeholder documentation for __listOf__string |
cluster_id | string | Placeholder documentation for __string |
connection_state | string | The current connection state of the Node. (CONNECTED, DISCONNECTED) |
id | string | Placeholder documentation for __string |
instance_arn | string | Placeholder documentation for __string |
managed_instance_id | string | Placeholder documentation for __string |
name | string | Placeholder documentation for __string |
node_interface_mappings | array | Documentation update needed |
role | string | Used in CreateNodeRequest, CreateNodeRegistrationScriptRequest, DescribeNodeResult, DescribeNodeSummary, UpdateNodeRequest. (BACKUP, ACTIVE) |
sdi_source_mappings | array | An array of SDI source mappings. Each mapping connects one logical SdiSource to the physical SDI card and port that the physical SDI source uses. |
state | string | The current state of the Node. (CREATED, REGISTERING, READY_TO_ACTIVATE, REGISTRATION_FAILED, ACTIVATION_FAILED, ACTIVE, READY, IN_USE, DEREGISTERING, DRAINING, DEREGISTRATION_FAILED, DEREGISTERED) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_node | select | cluster_id, node_id, region | Get details about a Node in the specified Cluster. | |
list_nodes | select | cluster_id, region | maxResults, nextToken | Retrieve the list of Nodes. |
create_node | insert | cluster_id, region | Create a Node in the specified Cluster. You can also create Nodes using the CreateNodeRegistrationScript. Note that you can't move a Node to another Cluster. | |
update_node | update | cluster_id, node_id, region | Change the settings for a Node. | |
delete_node | delete | cluster_id, node_id, region | Delete a Node. The Node must be IDLE. | |
create_node_registration_script | exec | cluster_id, region | Create the Register Node script for all the nodes intended for a specific Cluster. You will then run the script on each hardware unit that is intended for that Cluster. The script creates a Node in the specified Cluster. It then binds the Node to this hardware unit, and activates the node hardware for use with MediaLive Anywhere. | |
update_node_state | exec | cluster_id, node_id, region | Update the state of a node. |
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 |
|---|---|---|
cluster_id | string | The ID of the cluster |
node_id | string | The ID of the node. |
region | string | AWS region (default: us-east-1) |
maxResults | integer | The maximum number of items to return. |
nextToken | string | The token to retrieve the next page of results. |
SELECT examples
- describe_node
- list_nodes
Get details about a Node in the specified Cluster.
SELECT
arn,
channel_placement_groups,
cluster_id,
connection_state,
id,
instance_arn,
name,
node_interface_mappings,
role,
sdi_source_mappings,
state
FROM aws.medialive.nodes
WHERE cluster_id = '{{ cluster_id }}' -- required
AND node_id = '{{ node_id }}' -- required
AND region = '{{ region }}' -- required
;
Retrieve the list of Nodes.
SELECT
arn,
channel_placement_groups,
cluster_id,
connection_state,
id,
instance_arn,
managed_instance_id,
name,
node_interface_mappings,
role,
sdi_source_mappings,
state
FROM aws.medialive.nodes
WHERE cluster_id = '{{ cluster_id }}' -- required
AND region = '{{ region }}' -- required
AND maxResults = '{{ maxResults }}'
AND nextToken = '{{ nextToken }}'
;
INSERT examples
- create_node
- Manifest
Create a Node in the specified Cluster. You can also create Nodes using the CreateNodeRegistrationScript. Note that you can't move a Node to another Cluster.
INSERT INTO aws.medialive.nodes (
Name,
NodeInterfaceMappings,
RequestId,
Role,
Tags,
cluster_id,
region
)
SELECT
'{{ Name }}',
'{{ NodeInterfaceMappings }}',
'{{ RequestId }}',
'{{ Role }}',
'{{ Tags }}',
'{{ cluster_id }}',
'{{ region }}'
RETURNING
arn,
channel_placement_groups,
cluster_id,
connection_state,
id,
instance_arn,
name,
node_interface_mappings,
role,
sdi_source_mappings,
state
;
# Description fields are for documentation purposes
- name: nodes
props:
- name: cluster_id
value: "{{ cluster_id }}"
description: Required parameter for the nodes resource.
- name: region
value: "{{ region }}"
description: Required parameter for the nodes resource.
- name: Name
value: "{{ Name }}"
description: |
Placeholder documentation for __string
- name: NodeInterfaceMappings
description: |
Placeholder documentation for __listOfNodeInterfaceMappingCreateRequest
value:
- LogicalInterfaceName: "{{ LogicalInterfaceName }}"
NetworkInterfaceMode: "{{ NetworkInterfaceMode }}"
PhysicalInterfaceName: "{{ PhysicalInterfaceName }}"
- name: RequestId
value: "{{ RequestId }}"
description: |
Placeholder documentation for __string
- name: Role
value: "{{ Role }}"
description: |
Used in CreateNodeRequest, CreateNodeRegistrationScriptRequest, DescribeNodeResult, DescribeNodeSummary, UpdateNodeRequest.
valid_values: ['BACKUP', 'ACTIVE']
- name: Tags
value: "{{ Tags }}"
description: |
Placeholder documentation for Tags
UPDATE examples
- update_node
Change the settings for a Node.
UPDATE aws.medialive.nodes
SET
Name = '{{ Name }}',
Role = '{{ Role }}',
SdiSourceMappings = '{{ SdiSourceMappings }}'
WHERE
cluster_id = '{{ cluster_id }}' --required
AND node_id = '{{ node_id }}' --required
AND region = '{{ region }}' --required
RETURNING
arn,
channel_placement_groups,
cluster_id,
connection_state,
id,
instance_arn,
name,
node_interface_mappings,
role,
sdi_source_mappings,
state;
DELETE examples
- delete_node
Delete a Node. The Node must be IDLE.
DELETE FROM aws.medialive.nodes
WHERE cluster_id = '{{ cluster_id }}' --required
AND node_id = '{{ node_id }}' --required
AND region = '{{ region }}' --required
;
Lifecycle Methods
- create_node_registration_script
- update_node_state
Create the Register Node script for all the nodes intended for a specific Cluster. You will then run the script on each hardware unit that is intended for that Cluster. The script creates a Node in the specified Cluster. It then binds the Node to this hardware unit, and activates the node hardware for use with MediaLive Anywhere.
EXEC aws.medialive.nodes.create_node_registration_script
@cluster_id='{{ cluster_id }}' --required,
@region='{{ region }}' --required
@@json=
'{
"Id": "{{ Id }}",
"Name": "{{ Name }}",
"NodeInterfaceMappings": "{{ NodeInterfaceMappings }}",
"RequestId": "{{ RequestId }}",
"Role": "{{ Role }}"
}'
;
Update the state of a node.
EXEC aws.medialive.nodes.update_node_state
@cluster_id='{{ cluster_id }}' --required,
@node_id='{{ node_id }}' --required,
@region='{{ region }}' --required
@@json=
'{
"State": "{{ State }}"
}'
;