Setting Migration Rate Limit Rules for a Migration Task
Function
This API is used to set migration rate limit rules for a migration task.
URI
POST /v3/tasks/{task_id}/speed-limit
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
task_id |
Yes |
String |
Specifies the migration task ID for which you set migration rate limit. Minimum length: 0 characters Maximum length: 255 characters |
Request
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
Specifies the user token. It can be obtained by calling the IAM API (value of X-Subject-Token in the response header). Minimum length: 1 character Maximum length: 16,384 characters |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
speed_limit |
Yes |
Array of SpeedLimitlJson objects |
Specifies the information about the time segment-based migration rate limit rules. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
start |
Yes |
String |
Specifies the start time of a segment. The format is XX:XX. Minimum length: 0 characters Maximum length: 255 characters |
end |
Yes |
String |
Specifies the end time of a segment. The format is XX:XX. Minimum length: 0 characters Maximum length: 255 characters |
speed |
Yes |
Integer |
Specifies the migration rate limit for the specified period of time. The value is an integer ranging from 0 to 1000. The unit is Mbit/s. Minimum value: 0 Maximum value: 10000 |
Response
None
Example Request
- Set migration rate limit for the task whose ID is 7a9a9540-ff28-4869-b9e4-855fbe12e83b.
POST https://{endpoint}/v3/tasks/7a9a9540-ff28-4869-b9e4-855fbe12e83b/speed-limit { "speed_limit" : [ { "start" : "00:00", "end" : "23:59", "speed" : 0 } ] }
- Update the migration rate limit of the task whose ID is a45a300b-86b5-4b13-8802-52274fa43016.
POST https://{endpoint}/v3/tasks/a45a300b-86b5-4b13-8802-52274fa43016/speed-limit { "speed_limit" : [ { "start" : "0:00", "end" : "8:00", "speed" : 20 }, { "start" : "8:00", "end" : "15:00", "speed" : 50 }, { "start" : "15:00", "end" : "23:59", "speed" : 25 } ] }
Example Response
None
Status Codes
Status Code |
Description |
---|---|
200 |
OK |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot