Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: retry non-idempotent long-running RPCs #141

Merged
merged 5 commits into from Apr 13, 2020

Commits on Apr 10, 2020

  1. fix: retry non-idempotent long-running RPCs

    RPCs returning a long-running operation, such as CreateDatabase,
    CreateBackup and RestoreDatabase, are non-idempotent and cannot be
    retried automatically by gax. This means that these RPCs sometimes fail
    with transient errors, such as UNAVAILABLE or DEADLINE_EXCEEDED. This
    change introduces automatic retries of these RPCs using the following
    logic:
    1. Execute the RPC and wait for the operation to be returned.
    2. If a transient error occurs while waiting for the operation, the
       client library queries the backend for the corresponding operation.
       If the operation is found, the resumes the tracking of the existing
       operation and returns that to the user.
    3. If no corresponding operation is found in step 2, the client library
       retries the RPC from step 1.
    
    Fixes GoogleCloudPlatform/java-docs-samples#2571
    olavloite committed Apr 10, 2020
    Copy the full SHA
    5bbb6fc View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    e329a1b View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    cd96869 View commit details
    Browse the repository at this point in the history
  4. Copy the full SHA
    1e9c4a6 View commit details
    Browse the repository at this point in the history
  5. Copy the full SHA
    605b672 View commit details
    Browse the repository at this point in the history