標準と自動スケールのスループット間で移行する
手動でスループットをプロビジョニングしたコンテナーを、自動スケールのスループットに移行できます。 az cosmosdb sql container throughput migrate コマンドには、--throughput-type という特殊な引数が含まれています。この引数には、autoscale または manual の値を設定できます。
--throughput-type 引数を autoscale に設定した az cosmosdb sql container throughput migrate コマンドを使用して、コンテナーを自動スケールのスループットに移行します。
az cosmosdb sql container throughput migrate \
--account-name '<account-name>' \
--resource-group '<resource-group>' \
--database-name '<database-name>' \
--name '<container-name>' \
--throughput-type 'autoscale'
移行が完了したら、az cosmosdb sql container throughput update コマンドと --max-throughput 引数を使用して、許容される最大スループットを管理できます。 この例では、最大スループットが 5000 RU/秒に変更されています。
az cosmosdb sql container throughput update \
--account-name '<account-name>' \
--resource-group '<resource-group>' \
--database-name '<database-name>' \
--name '<container-name>' \
--max-throughput '5000'
az cosmosdb sql container throughput show コマンドを呼び出して、自動スケーリング コンテナーの最小スループットを表示することもできます
az cosmosdb sql container throughput show \
--account-name '<account-name>' \
--resource-group '<resource-group>' \
--database-name '<database-name>' \
--name '<container-name>' \
--query 'resource.minimumThroughput' \
--output 'tsv'
--throughput-type 引数を manual に設定して az cosmosdb sql container throughput migrate コマンドを呼び出すことで、いつでもコンテナーを手動でプロビジョニングされたスループットに移行できます
az cosmosdb sql container throughput migrate \
--account-name '<account-name>' \
--resource-group '<resource-group>' \
--database-name '<database-name>' \
--name '<container-name>' \
--throughput-type 'manual'