Create a new token to reserve the split load
POST /storage/file/clone/tokens
Introduced In: 9.10
Creates a new token to reserve the split load.
Required Properties
-
node.uuid -
reserve-size
Optional Properties
-
expiry_time.limit
Default values
-
expiry_time.limit- "60"
Related ONTAP Commands
-
volume file clone token create
Learn More
-
[
DOC /storage/file/clone]
Creating clone tokens to reserve space for clone creation on the node
There is a limit on the amount of clone data that can undergo a split at a point of time on the node (clone split load). Clone tokens are used to reserve space from clone split load for clone creation. The POST operation is used to create clone tokens with reserve-size and expiry-time.limit in the body.<br>
# The API
/api/storage/file/clone/tokens
# The call
curl -X POST "https://<mgmt_ip>/api/storage/file/clone/tokens" -H "accept: application/hal+json" -d '{"node": {"uuid": "97255711-a1ad-11eb-92b2-0050568eb2ca"}, "reserve_size": "40M", "expiry_time": { "limit": "4200"} }'
# The response
{
"num_records": 1,
"records": [
{
"node": {
"uuid": "97255711-a1ad-11eb-92b2-0050568eb2ca",
"name": "node1"
},
"uuid": "286f6ae4-c94d-11eb-adb5-005056bbeb0b",
"reserve_size": 41943040,
"expiry_time": {
"limit": "PT1H10M"
},
"_links": {
"self": {
"href": "/api/storage/file/clone/tokens/97255711-a1ad-11eb-92b2-0050568eb2ca"
}
}
}
]
}
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
return_records |
boolean |
query |
False |
The default is false. If set to true, the records are returned.
|
Request Body
| Name | Type | Description |
|---|---|---|
expiry_time |
||
node |
||
reserve_size |
integer |
Specifies the available reserve in the file clone split load for the given token. Also note that the minimum value for reserve size is 4KB and any value specified below 4KB will be rounded off to 4KB. |
uuid |
string |
Token UUID. |
Response
Status: 201, Created
| Name | Type | Description |
|---|---|---|
num_records |
integer |
Number of records. |
records |
array[token] |
Example response
{
"num_records": 1,
"records": [
{}
]
}
Headers
| Name | Description | Type |
|---|---|---|
Location |
Useful for tracking the resource location |
string |
Error
Status: Default
ONTAP Error Response Codes
| Error Code | Description |
|---|---|
13565959 |
Failed to create token for node |
13565964 |
Reserve size cannot be negative. |
13565997 |
The node.uuid doesn't exist. |
Also see the table of common errors in the Response body overview section of this documentation.
Definitions
See Definitions
href
| Name | Type | Description |
|---|---|---|
href |
string |
self_link
expiry_time
| Name | Type | Description |
|---|---|---|
left |
string |
Specifies the time remaining before the given token expires in ISO-8601 format. |
limit |
string |
Specifies when the given token expires in ISO-8601 format. |
node
| Name | Type | Description |
|---|---|---|
name |
string |
Node name |
uuid |
string |
Node UUID |
token
token
| Name | Type | Description |
|---|---|---|
expiry_time |
||
node |
||
reserve_size |
integer |
Specifies the available reserve in the file clone split load for the given token. Also note that the minimum value for reserve size is 4KB and any value specified below 4KB will be rounded off to 4KB. |
uuid |
string |
Token UUID. |
collection_links
error_arguments
| Name | Type | Description |
|---|---|---|
code |
string |
Argument code |
message |
string |
Message argument |
returned_error
| Name | Type | Description |
|---|---|---|
arguments |
array[error_arguments] |
Message arguments |
code |
string |
Error code |
message |
string |
Error message |
target |
string |
The target parameter that caused the error. |