StorageGateway / Client / update_bandwidth_rate_limit
update_bandwidth_rate_limit#
- StorageGateway.Client.update_bandwidth_rate_limit(**kwargs)#
Updates the bandwidth rate limits of a gateway. You can update both the upload and download bandwidth rate limit or specify only one of the two. If you don’t set a bandwidth rate limit, the existing rate limit remains. This operation is supported only for the stored volume, cached volume, and tape gateway types. To update bandwidth rate limits for S3 file gateways, use UpdateBandwidthRateLimitSchedule.
By default, a gateway’s bandwidth rate limits are not set. If you don’t set any limit, the gateway does not have any limitations on its bandwidth usage and could potentially use the maximum available bandwidth.
To specify which gateway to update, use the Amazon Resource Name (ARN) of the gateway in your request.
See also: AWS API Documentation
Request Syntax
response = client.update_bandwidth_rate_limit( GatewayARN='string', AverageUploadRateLimitInBitsPerSec=123, AverageDownloadRateLimitInBitsPerSec=123 )
- Parameters:
GatewayARN (string) –
[REQUIRED]
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and Amazon Web Services Region.
AverageUploadRateLimitInBitsPerSec (integer) – The average upload bandwidth rate limit in bits per second.
AverageDownloadRateLimitInBitsPerSec (integer) – The average download bandwidth rate limit in bits per second.
- Return type:
dict
- Returns:
Response Syntax
{ 'GatewayARN': 'string' }
Response Structure
(dict) –
A JSON object containing the Amazon Resource Name (ARN) of the gateway whose throttle information was updated.
GatewayARN (string) –
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and Amazon Web Services Region.
Exceptions
Examples
Updates the bandwidth rate limits of a gateway. Both the upload and download bandwidth rate limit can be set, or either one of the two. If a new limit is not set, the existing rate limit remains.
response = client.update_bandwidth_rate_limit( AverageDownloadRateLimitInBitsPerSec=102400, AverageUploadRateLimitInBitsPerSec=51200, GatewayARN='arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B', ) print(response)
Expected Output:
{ 'GatewayARN': 'arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B', 'ResponseMetadata': { '...': '...', }, }