Service Quotas API in Confluent Cloud¶
Use the Service Quotas API to discover all the quotas that exist in Confluent Cloud and how close you are to exceeding your limits. For more information on default limit values, see Confluent Cloud のサービスクォータ.
重要
The Service Quotas API is currently available on Confluent Cloud in a Public Preview for early adopters. A Public Preview feature is a component of Confluent Cloud introduced to gain feedback. This feature should be used only for evaluation and non-production testing purposes or to provide feedback to Confluent, particularly as it becomes more widely available in follow-on preview editions. If you would like to participate in the Public Preview, email quotas-api-access@confluent.io.
Public Preview features are intended for evaluation use in development and testing environments only, and not for production use. The warranty, SLA, and Support Services provisions of your agreement with Confluent do not apply to Public Preview features. Public Preview features are considered to be a Proof of Concept as defined in the Confluent Cloud Terms of Service. Confluent may discontinue providing preview releases of the Public Preview features at any time in Confluent's sole discretion.
Cloud API キーおよびシークレットの取得¶
To communicate with the Service Quotas API, you need a Confluent Cloud API key and API secret. You can generate an API key pair by using the Confluent CLI or Cloud Console.
confluent login コマンドを使用し、認証情報を指定してログインします。
次のコマンドを実行して、API キーとシークレットを作成します。
confluent api-key create --resource cloud --description <key_description>
出力は以下のようになります。
It may take a couple of minutes for the API key to be ready. Save the API key and secret. The secret is not retrievable later. +---------+------------------------------------------------------------------+ | API Key | 4U5U9B0BIMPSXIXX | | Secret | 7oNqCMSI890Ay7CeGBoBDoBBsSttOMJ5oFUwwkhj7g7MlS3p01c99C6ao84pQb8X | +---------+------------------------------------------------------------------+
詳細については、「Cloud API キーの作成」を参照してください。
Cloud Console で Administration メニューを開いて Cloud API keys をクリックするか、https://confluent.cloud/settings/api-keys にアクセスします。
Add key をクリックし、手順に従います。
詳細については、「Cloud API キーの数」を参照してください。
API キーと API シークレットを生成したら、安全でセキュアな場所に保存します。これらは、Quotas API に対するすべての呼び出しで、認証に必要になります。
注釈
Cloud API キーは、Kafka クラスターの API キーとは異なります。Confluent Cloud API の呼び出しにクラスターの API キーを使用することはできません。
Service Quotas API endpoints¶
以下のスコープに対して現在適用されている制限に関するクエリを実行できます。
スコープパラメーター | 説明 |
---|---|
organization |
組織に適用される制限 |
user_account |
ユーザーアカウントの制限 |
service_account |
サービスプリンシパル アカウントの制限 |
environment |
組織内の環境に適用される制限 |
kafka_cluster |
Kafka クラスターに適用される制限 |
network |
Limits applied to networks |
Access the Service Quotas API by making requests to the following endpoints.
- スコープ
クォータを適用できる、使用可能なスコープを取得します。
https://api.confluent.cloud/service-quota/v1/scopes
- 組織
組織に適用される制限を取得します。
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=organization
- サービスアカウント
サービスプリンシパル アカウントに適用される制限を取得します。
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=service_account
- ユーザーアカウント
ユーザープリンシパルアカウントに適用される制限を取得します。
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=user_account
- 環境
環境に適用される制限を取得します。
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=environment
- Kafka クラスター
Kafka クラスターに適用される制限を取得します。
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=kafka_cluster
- Network
Get the limits that are applied to your networks.
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=network
Query a Service Quotas endpoint¶
Requests to the Service Quotas API have two possible request formats.
List of quotas: Use the following format to retrieve a list of applied quotas:
https://api.confluent.cloud/service-quota/v1/applied-quotas?<param1>=<value1>&<param2>=<value2>&...
For example, the following request gets a list of all applied quotas in your environment:
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=environment
List requests require the
scope
parameter and may have optional parameters, likepage_size
.Single quota: Use the following format to read a particular applied quota:
https://api.confluent.cloud/service-quota/v1/applied-quotas/<quota-id>?<param1>=<value1>&<param2>=<value2>&...
For example, to get the quota for the maximum number of Kafka clusters in a specific environment, provide the
kafka.max_kafka_clusters.per_env
quota ID and the environment ID:https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_kafka_clusters.per_env?environment=<env-id>
A request to read a specific quota must specify a combination of identifiers for the environment, cluster, or network, depending on the context.
In a command shell, you can access the endpoints by using the curl
command.
Use the API key and API secret that you saved earlier as the user name and
password for the --user
option. Remember to separate them with the :
character.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?<param1>=<value1>&<param2>=<value2>&...' \
--user '<api-key>:<api-secret>'
応答は JSON であるため、jq
などのツールを使用して、ページトークンなどのクォータの値およびメタデータを取得できます。
注釈
- The Applied Quotas response objects have a field named
usage
that appears only if the requested quota supports usage data. If the quota doesn’t support usage data, nousage
attribute is returned in the response body.
応答のページ化¶
クォータの一覧が長くなる場合、ページ化された応答をリクエストすることができます。たとえば、次のリクエストでは、page_size
として 2 を指定しています。
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=organization&page_size=2
JSON 応答には、結果の次のページをリクエストする URL を持つ next
キーがあります。次のコマンドは、jq
を使用してキーを抽出する方法を示しています。これにより、次のリクエストでそのキーを使用できます。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=organization&page_size=2' \
--user '<api-key>:<api-secret>' \
| jq '.metadata | {next}'
出力は以下のようになります。
{
"next": "https://api.confluent.cloud/service-quota/v1/applied-quotas?page_token=eyBOB29wZSI6Im9yZ2FuaXphdGlvBiIsIklkIjoiaWFtLm1heF9rYWZrYV9jbHVzdGVycy5wZXJfb3JnIiwiRW52aXJvbm1lbnQiOiIiLCJLYWZrYUNsdXN0ZXIiOiIiLCJQYWdlU2l6ZSI6OiwiRW52aXJvbm1lbnRGaWx0ZXIiOiIiLCJDbHVzdGVyRmlsdGVyIjoiIn0="
}
別のリクエストで next
の URL を省略せずに使用すると、次のページを取得できます。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?page_token=eyBOB29wZSI6Im9yZ2FuaXphdGlvBiIsIklkIjoiaWFtLm1heF9rYWZrYV9jbHVzdGVycy5wZXJfb3JnIiwiRW52aXJvbm1lbnQiOiIiLCJLYWZrYUNsdXN0ZXIiOiIiLCJQYWdlU2l6ZSI6OiwiRW52aXJvbm1lbnRGaWx0ZXIiOiIiLCJDbHVzdGVyRmlsdGVyIjoiIn0=' \
--user '<api-key>:<api-secret>'
Example requests¶
The following example commands show how to query for many of the applied quota limits, but they don't comprise an exhaustive list.
スコープのクエリ¶
次のコマンドを実行すると、使用可能なクォータのスコープを問い合わせるクエリを実行できます。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/scopes' \
--user '<api-key>:<api-secret>'
| jq '.data[] | {id}'
出力は以下のようになります。
{
"id": "user_account"
}
{
"id": "service_account"
}
{
"id": "organization"
}
{
"id": "environment"
}
{
"id": "network"
}
{
"id": "kafka_cluster"
}
applied-quotas
エンドポイントに対するリクエストの scope
パラメーターには id
文字列を使用します。たとえば、次のリクエストでは、環境に対してアクティブなクォータを取得できます。
https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=environment
Organization quotas¶
次の表は、Organization スコープに対して取得できるクォータの一覧です。デフォルト値については、「組織のクォータ」を参照してください。
クォータ(最大数) | Service Quotas code |
---|---|
組織ごとの環境の数 | iam.max_environments.per_org |
組織ごとの Kafka クラスターの数 | iam.max_kafka_clusters.per_org |
組織ごとの Cloud API キーの数 | iam.max_cloud_api_keys.per_org |
組織ごとのユーザーアカウントの数 | iam.max_users.per_org |
組織ごとのサービスアカウントの数 | iam.max_service_accounts.per_org |
組織ごとの監査ログコンシューマーの API キーの数 | iam.max_audit_log_api_keys.per_org |
1 日あたりの Kafka クラスターのプロビジョニングリクエスト数 | kafka.max_kafka_creation.per_day |
次のコマンドでは、組織に適用されるすべてのクォータをリクエストします。また、ここでは jq
を使用して JSON 応答をフィルター処理し、表示名、ID、各クォータの現在の値を表示しています。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=organization' \
--user '<api-key>:<api-secret>' \
| jq '.data[] | {display_name,id,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Audit Log API Keys Per Organization",
"id": "iam.max_audit_log_api_keys.per_org",
"applied_limit": 2
}
{
"display_name": "Max Cloud API Keys Per Organization",
"id": "iam.max_cloud_api_keys.per_org",
"applied_limit": 100
}
{
"display_name": "Max Environments Per Organization",
"id": "iam.max_environments.per_org",
"applied_limit": 10
}
{
"display_name": "Max Kafka Clusters Per Organization",
"id": "iam.max_kafka_clusters.per_org",
"applied_limit": 50
}
{
"display_name": "Max Service Accounts Per Organization",
"id": "iam.max_service_accounts.per_org",
"applied_limit": 100
}
{
"display_name": "Max Users Per Organization",
"id": "iam.max_users.per_org",
"applied_limit": 100
}
{
"display_name": "Max Kafka Cluster Provisioning Requests Per Day",
"id": "kafka.max_kafka_creation.per_day",
"applied_limit": 10
}
組織の Cloud API キーの最大数¶
次のコマンドでは、iam.max_cloud_api_keys.per_org
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_cloud_api_keys.per_org' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max API Keys Per Organization",
"applied_limit": 100
}
組織の環境の最大数¶
次のコマンドでは、iam.max_environments.per_org
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_environments.per_org' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Environments Per Organization",
"applied_limit": 10
}
組織の Kafka クラスターの最大数¶
次のコマンドでは、iam.max_kafka_clusters.per_org
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_kafka_clusters.per_org' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Kafka Clusters Per Organization",
"applied_limit": 50
}
組織のサービスアカウントの最大数¶
次のコマンドでは、iam.max_service_accounts.per_org
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_service_accounts.per_org' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Service Accounts Per Organization",
"applied_limit": 100
}
組織のユーザーアカウントの最大数¶
次のコマンドでは、iam.max_users.per_org
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_users.per_org' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Users Per Organization",
"applied_limit": 100
}
組織ごとの監査ログコンシューマーの API キーの最大数¶
次のコマンドでは、iam.max_audit_log_api_keys.per_org
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_audit_log_api_keys.per_org' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Audit Log API Keys Per Organization",
"applied_limit": 2
}
1 日あたりの Kafka クラスターのプロビジョニングリクエストの最大数¶
次のコマンドでは、kafka.max_kafka_creation.per_day
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_kafka_creation.per_day' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Kafka Cluster Provisioning Requests Per Day",
"applied_limit": 10
}
Service account quotas¶
次の表は、Service account スコープに対して取得できるクォータの一覧です。デフォルト値については、「サービスアカウントのクォータ」を参照してください。
クォータ(最大数) | Service Quotas code |
---|---|
Confluent Cloud API キー | iam.max_cloud_api_keys.per_service_account |
Kafka API キー | iam.max_kafka_api_keys.per_service_account |
次のコマンドでは、サービスアカウントに適用されるすべてのクォータをリクエストします。また、ここでは jq
を使用して JSON 応答をフィルター処理し、表示名、ID、各クォータの現在の値を表示しています。
注釈
- The response includes quotas for all service accounts.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=service_account' \
--user '<api-key>:<api-secret>' \
| jq '.data[] | {display_name,id,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Cloud API Keys Per Service Account",
"id": "iam.max_cloud_api_keys.per_service_account",
"applied_limit": 10
}
{
"display_name": "Max Kafka API Keys Per Service Account",
"id": "iam.max_kafka_api_keys.per_service_account",
"applied_limit": 10
}
サービスアカウントごとの Cloud API キーの最大数¶
次のコマンドでは、iam.max_cloud_api_keys.per_service_account
クォータをリクエストします。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_cloud_api_keys.per_service_account' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Cloud API Keys Per Service Account",
"applied_limit": 100
}
サービスアカウントごとの Kafka API キーの最大数¶
次のコマンドでは、iam.max_kafka_api_keys.per_service_account
クォータをリクエストします。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_kafka_api_keys.per_service_account' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Kafka API Keys Per Service Account",
"applied_limit": 100
}
User account quotas¶
次の表は、User account スコープに対して取得できるクォータの一覧です。デフォルト値については、「ユーザーアカウントのクォータ」を参照してください。
クォータ(最大数) | Service Quotas code |
---|---|
Confluent Cloud API キー | iam.max_cloud_api_keys.per_user |
Kafka API キー | iam.max_kafka_api_keys.per_user |
次のコマンドでは、ユーザーアカウントに適用されるすべてのクォータをリクエストします。また、ここでは jq
を使用して JSON 応答をフィルター処理し、表示名、ID、各クォータの現在の値を表示しています。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=user_account' \
--user '<api-key>:<api-secret>' \
| jq '.data[] | {display_name,id,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Cloud API Keys Per User",
"id": "iam.max_cloud_api_keys.per_user",
"applied_limit": 100
}
{
"display_name": "Max Kafka API Keys Per User",
"id": "iam.max_kafka_api_keys.per_user",
"applied_limit": 100
}
ユーザーごとの Cloud API キーの最大数¶
次のコマンドでは、iam.max_cloud_api_keys.per_user
クォータをリクエストします。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_cloud_api_keys.per_user' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Cloud API Keys Per User Account",
"applied_limit": 100
}
ユーザーごとの Kafka API キーの最大数¶
次のコマンドでは、iam.max_kafka_api_keys.per_user
クォータをリクエストします。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/iam.max_kafka_api_keys.per_user' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max Kafka API Keys Per User Account",
"applied_limit": 100
}
Environment quotas¶
次の表は、Environment スコープに対して取得できるクォータの一覧です。デフォルト値については、「環境のクォータ」を参照してください。
クォータ(最大数) | Service Quotas code |
---|---|
環境ごとの Kafka クラスターの数 | kafka.max_kafka_clusters.per_env |
環境ごとの保留中の Kafka クラスターの数 | kafka.max_pending_kafka_clusters.per_env |
環境ごとの Kafka クラスター CKU の数 | kafka.max_ckus.per_env |
環境ごとの ksqlDB アプリの数 | ksql.max_apps.per_env |
次のコマンドでは、環境でアクティブなすべてのクォータをリクエストします。また、ここでは jq
を使用して JSON 応答をフィルター処理し、表示名、ID、各クォータの現在の値を表示しています。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=environment' \
--user '<api-key>:<api-secret>' \
| jq '.data[] | .environment.kind,.environment.id,{display_name,id,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
{
"display_name": "Max Kafka Cluster CKUs Per Environment",
"id": "kafka.max_ckus.per_env",
"applied_limit": 50
}
"Environment"
"env-yyyyy"
{
"display_name": "Max Kafka Clusters Per Environment",
"id": "kafka.max_kafka_clusters.per_env",
"applied_limit": 20
}
"Environment"
"env-yyyyy"
{
"display_name": "Max Pending Kafka Clusters Per Environment",
"id": "kafka.max_pending_kafka_clusters.per_env",
"applied_limit": 3
}
"Environment"
"env-yyyyy"
{
"display_name": "Max Ksql Apps Per Environment",
"id": "ksql.max_apps.per_env",
"applied_limit": 3
}
"Environment"
"env-yyyyy"
{
"display_name": "Max network per environment",
"id": "networking.max_network.per_environment",
"applied_limit": 3
}
環境 ID の取得¶
Environment quota endpoints require the environment ID. You can get it from
the Cloud Console, or you can use the confluent environment list
command.
以下のコマンドを実行すると、Confluent Cloud 環境の一覧を取得できます。
confluent environment list
出力は以下のようになります。
Id | Name
--------------+----------
* env-yyyyy | default
Cloud Console で Administration メニューを開いて Settings をクリックするか、https://confluent.cloud/settings/user-settings/identity にアクセスします。
Access をクリックし、組織の一覧で対象の環境をクリックします。環境 ID は詳細パネルに表示されます。
安全でセキュアな場所に環境 ID を保存します。
環境のクラスターの最大数¶
The following command requests the kafka.max_kafka_clusters.per_env
quota.
Replace <env-id>
, <api-key>
, and <api-secret>
with the values you
saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_kafka_clusters.per_env?environment=<env-id>' \
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,{display_name,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
{
"display_name": "Max Kafka Clusters Per Environment",
"applied_limit": 20
}
環境のクラスター CKU の最大数¶
The following command requests the kafka.max_ckus.per_env
quota.
Replace <env-id>
, <api-key>
, and <api-secret>
with the values you
saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_ckus.per_env?environment=<env-id>' \
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,{display_name,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
{
"display_name": "Max Kafka Cluster CKUs Per Environment",
"applied_limit": 50
}
環境の保留中のクラスターの最大数¶
The following command requests the kafka.max_pending_kafka_clusters.per_env
quota. Replace <env-id>
, <api-key>
, and <api-secret>
with the values
you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_pending_kafka_clusters.per_env?environment=<env-id>'
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,{display_name,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
{
"display_name": "Max Pending Kafka Clusters Per Environment",
"applied_limit": 3
}
Max ksqlDB clusters for an environment¶
The following command requests the ksql.max_apps.per_env
quota. Replace <env-id>
, <api-key>
, and <api-secret>
with the
values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/ksql.max_apps.per_env?environment=<env-id>'
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,{display_name,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
{
"display_name": "Max Ksql Apps Per Environment",
"applied_limit": 3
}
Kafka cluster quotas¶
次の表は、Kafka cluster スコープに対して取得できるクォータの一覧です。デフォルト値については、「Kafka クラスターのクォータ」を参照してください。
クォータ(最大数) | Service Quotas code |
---|---|
(専用)|ak| API キー | kafka.max_api_keys.per_cluster |
(スタンダード)|ak| API キー | kafka.max_api_keys.per_cluster |
(ベーシック)|ak| API キー | kafka.max_api_keys.per_cluster |
クラスターへの PrivateLink 接続を作成できるアカウントの数 | kafka.max_private_links.per_cluster |
ピアリング接続数 | kafka.max_peering.per_cluster |
CKU 数 | kafka.max_ckus.per_cluster |
注釈
- API キーのクォータには、ユーザーアカウントおよびサービスアカウントが所有するキーが含まれます。
- The response includes quotas for all clusters.
次のコマンドでは、Kafka クラスターに適用されるすべてのクォータをリクエストします。また、ここでは jq
を使用して JSON 応答をフィルター処理し、表示名、ID、各クォータの現在の値を表示しています。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=kafka_cluster' \
--user '<api-key>:<api-secret>' \
| jq '.data[] | {display_name,id,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max API Keys Per Kafka Cluster",
"id": "kafka.max_api_keys.per_cluster",
"applied_limit": 100
}
{
"display_name": "Max CKUs Per Kafka Cluster",
"id": "kafka.max_ckus.per_cluster",
"applied_limit": 4
}
{
"display_name": "Max Peering Connections Per Kafka Cluster",
"id": "kafka.max_peering.per_cluster",
"applied_limit": 5
}
{
"display_name": "Max Private Links Per Kafka Cluster",
"id": "kafka.max_private_links.per_cluster",
"applied_limit": 10
}
Kafka クラスター ID の取得¶
Kafka クラスターのクォータには、クラスター ID パラメーターが必要です。Confluent Cloud で Cluster settings ページを開くか、または次の ccloud
コマンドを使用して、クラスター ID を取得します。
confluent kafka cluster list
出力は以下のようになります。
Id | Name | Type | Provider | Region | Availability | Status
+--------------+-----------+-------+----------+-------------+--------------+--------+
* lkc-xxxxxx | cluster_0 | BASIC | gcp | us-central1 | single-zone | UP
In this example, the cluster ID is lkc-xxxxxx
.
Kafka クラスターごとの API キーの最大数¶
次のコマンドでは、kafka.max_api_keys.per_cluster
クォータをリクエストします。
Replace <api-key>
and <api-secret>
with the values you saved earlier.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_api_keys.per_cluster?scope=kafka_cluster&environment=<env-id>&kafka_cluster=<cluster-id>' \
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,.kafka_cluster.kind,.kafka_cluster.id,{display_name,id,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
"Cluster"
"lkc-xxxxxx"
{
"display_name": "Max API Keys Per Kafka Cluster",
"id": "kafka.max_api_keys.per_cluster",
"applied_limit": 20
}
Kafka クラスターごとのプライベートリンクの最大数¶
次のコマンドでは、kafka.max_private_links.per_cluster
クォータをリクエストします。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_private_links.per_cluster?scope=kafka_cluster&environment=<env-id>&kafka_cluster=<cluster-id>' \
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,.kafka_cluster.kind,.kafka_cluster.id,{display_name,id,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
"Cluster"
"lkc-xxxxxx"
{
"display_name": "Max Private Links Per Kafka Cluster",
"id": "kafka.max_private_links.per_cluster",
"applied_limit": 10
}
Kafka クラスターごとのピアリング接続の最大数¶
次のコマンドでは、kafka.max_peering.per_cluster
クォータをリクエストします。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_peering.per_cluster?scope=kafka_cluster&environment=<env-id>&kafka_cluster=<cluster-id>' \
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,.kafka_cluster.kind,.kafka_cluster.id,{display_name,id,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
"Cluster"
"lkc-xxxxxx"
{
"display_name": "Max Peering Connections Per Kafka Cluster",
"id": "kafka.max_peering.per_cluster",
"applied_limit": 5
}
Kafka クラスターごとの CKU の最大数¶
次のコマンドでは、kafka.max_ckus.per_cluster
クォータをリクエストします。
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/kafka.max_ckus.per_cluster?scope=kafka_cluster&environment=<env-id>&kafka_cluster=<cluster-id>' \
--user '<api-key>:<api-secret>' \
| jq '.environment.kind,.environment.id,.kafka_cluster.kind,.kafka_cluster.id,{display_name,id,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
"Cluster"
"lkc-xxxxxx"
{
"display_name": "Max CKUs Per Kafka Cluster",
"id": "kafka.max_ckus.per_cluster",
"applied_limit": 4
}
Network quotas¶
The following table shows the quotas that you can get for the Network scope. For default values, see Network quotas.
クォータ(最大数) | Quotas のサービスコード |
---|---|
Number of peering connections per Kafka cluster | networking.max_peering.per_network |
Number of private links per Kafka cluster | networking.max_private_link.per_network |
Number of transit gateways per Kafka cluster | networking.max_transit_gateway.per_network |
The following command requests all of the quotas that apply to networks.
Also, it uses jq
to filter the JSON response and show the display name, ID,
and current value for each quota.
注釈
- The response includes quotas for all networks.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas?scope=network' \
--user '<api-key>:<api-secret>' \
| jq '.data[] | .environment.kind,.environment.id,{display_name,id,applied_limit}'
出力は以下のようになります。
"Environment"
"env-yyyyy"
{
"display_name": "Max peering per network",
"id": "networking.max_peering.per_network",
"applied_limit": 25
}
"Environment"
"env-yyyyy"
{
"display_name": "Max private link per network",
"id": "networking.max_private_link.per_network",
"applied_limit": 10
}
"Environment"
"env-yyyyy"
{
"display_name": "Max transit gateway per network",
"id": "networking.max_transit_gateway.per_network",
"applied_limit": 1
}
Kafka クラスターごとのピアリング接続の最大数¶
The following command requests the networking.max_peering.per_network
quota.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/networking.max_peering.per_network?scope=network&environment=<env-id>&network=<network-id>' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max peering per network",
"applied_limit": 25
}
Kafka クラスターごとのプライベートリンクの最大数¶
The following command requests the networking.max_private_link.per_network
quota.
curl --request GET \
--url 'https://api.confluent.cloud/service-quota/v1/applied-quotas/networking.max_private_link.per_network?scope=network&environment=<env-id>&network=<network-id>' \
--user '<api-key>:<api-secret>' \
| jq '{display_name,applied_limit}'
出力は以下のようになります。
{
"display_name": "Max private link per network",
"applied_limit": 10
}