feat: migrate bigtable retry/timeout settings to gRPC's service configs
Committer: @miraleung PiperOrigin-RevId: 346894665
This commit is contained in:
parent
53eb2512a5
commit
cbbd3170bc
|
|
@ -21,250 +21,61 @@ language_settings:
|
|||
package_name: admin.v2
|
||||
interfaces:
|
||||
- name: google.bigtable.admin.v2.BigtableInstanceAdmin
|
||||
retry_params_def:
|
||||
- name: idempotent_params
|
||||
initial_retry_delay_millis: 1000
|
||||
retry_delay_multiplier: 2
|
||||
max_retry_delay_millis: 60000
|
||||
initial_rpc_timeout_millis: 60000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 60000
|
||||
total_timeout_millis: 600000
|
||||
- name: non_idempotent_params
|
||||
initial_retry_delay_millis: 0
|
||||
retry_delay_multiplier: 1
|
||||
max_retry_delay_millis: 0
|
||||
initial_rpc_timeout_millis: 60000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 60000
|
||||
total_timeout_millis: 60000
|
||||
- name: non_idempotent_heavy_params
|
||||
initial_retry_delay_millis: 0
|
||||
retry_delay_multiplier: 1
|
||||
max_retry_delay_millis: 0
|
||||
initial_rpc_timeout_millis: 300000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 300000
|
||||
total_timeout_millis: 300000
|
||||
methods:
|
||||
- name: CreateInstance
|
||||
retry_params_name: non_idempotent_heavy_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 500
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 5000
|
||||
total_poll_timeout_millis: 600000
|
||||
- name: GetInstance
|
||||
retry_params_name: idempotent_params
|
||||
- name: ListInstances
|
||||
retry_params_name: idempotent_params
|
||||
- name: UpdateInstance
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
surface_treatments:
|
||||
- include_languages: [java, csharp]
|
||||
visibility: DISABLED
|
||||
- name: PartialUpdateInstance
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 500
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 5000
|
||||
total_poll_timeout_millis: 600000
|
||||
- name: DeleteInstance
|
||||
retry_params_name: non_idempotent_params
|
||||
- name: CreateCluster
|
||||
retry_params_name: non_idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 5000
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 60000
|
||||
total_poll_timeout_millis: 21600000
|
||||
- name: GetCluster
|
||||
retry_params_name: idempotent_params
|
||||
- name: ListClusters
|
||||
retry_params_name: idempotent_params
|
||||
- name: UpdateCluster
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 500
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 5000
|
||||
total_poll_timeout_millis: 600000
|
||||
- name: DeleteCluster
|
||||
retry_params_name: non_idempotent_params
|
||||
- name: CreateAppProfile
|
||||
retry_params_name: non_idempotent_params
|
||||
- name: GetAppProfile
|
||||
retry_params_name: idempotent_params
|
||||
- name: ListAppProfiles
|
||||
retry_params_name: idempotent_params
|
||||
- name: UpdateAppProfile
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 500
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 5000
|
||||
total_poll_timeout_millis: 600000
|
||||
- name: DeleteAppProfile
|
||||
retry_params_name: non_idempotent_params
|
||||
- name: GetIamPolicy
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
- name: SetIamPolicy
|
||||
retry_params_name: non_idempotent_params
|
||||
- name: TestIamPermissions
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
|
||||
- name: google.bigtable.admin.v2.BigtableTableAdmin
|
||||
retry_params_def:
|
||||
- name: idempotent_params
|
||||
initial_retry_delay_millis: 1000
|
||||
retry_delay_multiplier: 2
|
||||
max_retry_delay_millis: 60000
|
||||
initial_rpc_timeout_millis: 60000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 60000
|
||||
total_timeout_millis: 600000
|
||||
- name: non_idempotent_params
|
||||
initial_retry_delay_millis: 0
|
||||
retry_delay_multiplier: 1
|
||||
max_retry_delay_millis: 0
|
||||
initial_rpc_timeout_millis: 60000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 60000
|
||||
total_timeout_millis: 60000
|
||||
- name: non_idempotent_heavy_params
|
||||
initial_retry_delay_millis: 0
|
||||
retry_delay_multiplier: 1
|
||||
max_retry_delay_millis: 0
|
||||
initial_rpc_timeout_millis: 300000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 300000
|
||||
total_timeout_millis: 300000
|
||||
- name: drop_row_range_params
|
||||
initial_retry_delay_millis: 0
|
||||
retry_delay_multiplier: 1
|
||||
max_retry_delay_millis: 0
|
||||
initial_rpc_timeout_millis: 3600000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 3600000
|
||||
total_timeout_millis: 3600000
|
||||
methods:
|
||||
- name: CreateTable
|
||||
retry_params_name: non_idempotent_heavy_params
|
||||
- name: CreateTableFromSnapshot
|
||||
retry_params_name: non_idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 5000
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 60000
|
||||
total_poll_timeout_millis: 3600000
|
||||
# Snapshots are Alpha-only and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: ListTables
|
||||
retry_params_name: idempotent_params
|
||||
- name: GetTable
|
||||
retry_params_name: idempotent_params
|
||||
- name: DeleteTable
|
||||
retry_params_name: non_idempotent_params
|
||||
- name: ModifyColumnFamilies
|
||||
retry_params_name: non_idempotent_heavy_params
|
||||
- name: DropRowRange
|
||||
retry_params_name: drop_row_range_params
|
||||
- name: GenerateConsistencyToken
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
- name: CheckConsistency
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
- name: GetIamPolicy
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
- name: SetIamPolicy
|
||||
retry_params_name: non_idempotent_params
|
||||
- name: TestIamPermissions
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
- name: SnapshotTable
|
||||
retry_params_name: non_idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 500
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 5000
|
||||
total_poll_timeout_millis: 600000
|
||||
# Snapshots are Alpha-only and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: GetSnapshot
|
||||
retry_params_name: idempotent_params
|
||||
# Snapshots are Alpha-only and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: ListSnapshots
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
# Snapshots are Alpha-only and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: DeleteSnapshot
|
||||
retry_params_name: non_idempotent_params
|
||||
# Snapshots are Alpha-only and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: CreateBackup
|
||||
retry_params_name: non_idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 500
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 5000
|
||||
total_poll_timeout_millis: 600000
|
||||
# Managed Backup is in alpha and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: GetBackup
|
||||
retry_params_name: idempotent_params
|
||||
# Managed Backup is in alpha and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: ListBackups
|
||||
retry_params_name: idempotent_params
|
||||
# Managed Backup is in alpha and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: UpdateBackup
|
||||
retry_params_name: non_idempotent_params
|
||||
# Managed Backup is in alpha and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: DeleteBackup
|
||||
retry_params_name: non_idempotent_params
|
||||
# Managed Backup is in alpha and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
- name: RestoreTable
|
||||
retry_params_name: non_idempotent_params
|
||||
long_running:
|
||||
initial_poll_delay_millis: 500
|
||||
poll_delay_multiplier: 1.5
|
||||
max_poll_delay_millis: 5000
|
||||
total_poll_timeout_millis: 600000
|
||||
# Managed Backup is in alpha and not supported in C#
|
||||
surface_treatments:
|
||||
- include_languages: [csharp]
|
||||
visibility: DISABLED
|
||||
|
|
|
|||
|
|
@ -15,10 +15,6 @@
|
|||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "CreateTableFromSnapshot"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "DeleteTable"
|
||||
|
|
@ -29,11 +25,15 @@
|
|||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "SnapshotTable"
|
||||
"method": "DeleteSnapshot"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "DeleteSnapshot"
|
||||
"method": "UpdateBackup"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "DeleteBackup"
|
||||
}
|
||||
],
|
||||
"timeout": "60s"
|
||||
|
|
@ -48,6 +48,28 @@
|
|||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "GetTable"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "GetSnapshot"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "GetBackup"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "ListBackups"
|
||||
}
|
||||
],
|
||||
"timeout": "60s",
|
||||
"retryPolicy": {
|
||||
"initialBackoff": "1s",
|
||||
"maxBackoff": "60s",
|
||||
"backoffMultiplier": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "GenerateConsistencyToken"
|
||||
|
|
@ -64,10 +86,6 @@
|
|||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "TestIamPermissions"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "GetSnapshot"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableTableAdmin",
|
||||
"method": "ListSnapshots"
|
||||
|
|
@ -75,7 +93,6 @@
|
|||
],
|
||||
"timeout": "60s",
|
||||
"retryPolicy": {
|
||||
"maxAttempts": 5,
|
||||
"initialBackoff": "1s",
|
||||
"maxBackoff": "60s",
|
||||
"backoffMultiplier": 2,
|
||||
|
|
@ -113,25 +130,17 @@
|
|||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "ListInstances"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "UpdateInstance"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "PartialUpdateInstance"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "GetCluster"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "ListClusters"
|
||||
"method": "UpdateCluster"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "UpdateCluster"
|
||||
"method": "ListClusters"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
|
|
@ -145,6 +154,14 @@
|
|||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "UpdateAppProfile"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "UpdateInstance"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "PartialUpdateInstance"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "GetIamPolicy"
|
||||
|
|
@ -172,10 +189,6 @@
|
|||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "DeleteInstance"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "CreateCluster"
|
||||
},
|
||||
{
|
||||
"service": "google.bigtable.admin.v2.BigtableInstanceAdmin",
|
||||
"method": "DeleteCluster"
|
||||
|
|
|
|||
|
|
@ -23,76 +23,3 @@ language_settings:
|
|||
domain_layer_location: google-cloud
|
||||
interfaces:
|
||||
- name: google.bigtable.v2.Bigtable
|
||||
collections:
|
||||
- entity_name: table
|
||||
language_overrides:
|
||||
- language: csharp
|
||||
common_resource_name: Google.Cloud.Bigtable.Common.V2.TableName
|
||||
retry_codes_def:
|
||||
- name: idempotent
|
||||
retry_codes:
|
||||
- UNAVAILABLE
|
||||
- DEADLINE_EXCEEDED
|
||||
- name: non_idempotent
|
||||
retry_codes: []
|
||||
retry_params_def:
|
||||
- name: idempotent_params
|
||||
initial_retry_delay_millis: 10
|
||||
retry_delay_multiplier: 2
|
||||
max_retry_delay_millis: 60000
|
||||
initial_rpc_timeout_millis: 20000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 20000
|
||||
total_timeout_millis: 600000
|
||||
- name: non_idempotent_params
|
||||
initial_retry_delay_millis: 10
|
||||
retry_delay_multiplier: 2
|
||||
max_retry_delay_millis: 60000
|
||||
initial_rpc_timeout_millis: 20000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 20000
|
||||
total_timeout_millis: 20000
|
||||
- name: read_rows_params
|
||||
initial_retry_delay_millis: 10
|
||||
retry_delay_multiplier: 2
|
||||
max_retry_delay_millis: 60000
|
||||
initial_rpc_timeout_millis: 300000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 300000
|
||||
total_timeout_millis: 43200000
|
||||
- name: mutate_rows_params
|
||||
initial_retry_delay_millis: 10
|
||||
retry_delay_multiplier: 2
|
||||
max_retry_delay_millis: 60000
|
||||
initial_rpc_timeout_millis: 60000
|
||||
rpc_timeout_multiplier: 1
|
||||
max_rpc_timeout_millis: 60000
|
||||
total_timeout_millis: 600000
|
||||
methods:
|
||||
- name: ReadRows
|
||||
# although ReadRows is idempotent, the retry logic requires complex resumption logic that should be handled manually at the client level
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: read_rows_params
|
||||
timeout_millis: 43200000
|
||||
- name: SampleRowKeys
|
||||
# although SampleRowKeys is idempotent, the retries should buffer and retry the entire stream as a whole, which should be handled manually at the client level
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: non_idempotent_params
|
||||
timeout_millis: 60000
|
||||
- name: MutateRow
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: idempotent_params
|
||||
timeout_millis: 60000
|
||||
- name: MutateRows
|
||||
# although MutateRows is idempotent (if serverside timestamps are not used), retries should be more granular and occur for groups of failed entries handled manually at the client level
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: mutate_rows_params
|
||||
timeout_millis: 600000
|
||||
- name: CheckAndMutateRow
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: non_idempotent_params
|
||||
timeout_millis: 20000
|
||||
- name: ReadModifyWriteRow
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: non_idempotent_params
|
||||
timeout_millis: 20000
|
||||
|
|
|
|||
|
|
@ -11,7 +11,12 @@
|
|||
"method": "ReadModifyWriteRow"
|
||||
}
|
||||
],
|
||||
"timeout": "20s"
|
||||
"timeout": "20s",
|
||||
"retryPolicy": {
|
||||
"initialBackoff": "0.010s",
|
||||
"maxBackoff": "60s",
|
||||
"backoffMultiplier": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
|
|
@ -20,7 +25,12 @@
|
|||
"method": "SampleRowKeys"
|
||||
}
|
||||
],
|
||||
"timeout": "60s"
|
||||
"timeout": "60s",
|
||||
"retryPolicy": {
|
||||
"initialBackoff": "0.010s",
|
||||
"maxBackoff": "60s",
|
||||
"backoffMultiplier": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
|
|
@ -29,7 +39,12 @@
|
|||
"method": "MutateRows"
|
||||
}
|
||||
],
|
||||
"timeout": "600s"
|
||||
"timeout": "600s",
|
||||
"retryPolicy": {
|
||||
"initialBackoff": "0.010s",
|
||||
"maxBackoff": "60s",
|
||||
"backoffMultiplier": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
|
|
@ -38,7 +53,12 @@
|
|||
"method": "ReadRows"
|
||||
}
|
||||
],
|
||||
"timeout": "43200s"
|
||||
"timeout": "43200s",
|
||||
"retryPolicy": {
|
||||
"initialBackoff": "0.010s",
|
||||
"maxBackoff": "60s",
|
||||
"backoffMultiplier": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
|
|
|
|||
Loading…
Reference in New Issue