Returns the retry predicate with the conditions specified for retrying.
FromErrorCodes(params int[])
public static RetryPredicate FromErrorCodes(params int[] errorCodes)
Returns a predicate which will retry on the specified HTTP error codes.
Note that only these error codes will be retried; the default error codes are not used by the returned predicate.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThis page provides reference documentation for the \u003ccode\u003eRetryPredicate\u003c/code\u003e class within the Google Cloud Storage v1 API, which is used to define conditions for retrying failed operations.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eRetryPredicate\u003c/code\u003e class is immutable and includes properties like \u003ccode\u003eNever\u003c/code\u003e to prevent retries and \u003ccode\u003eRetriableIdempotentErrors\u003c/code\u003e for default retryable error codes.\u003c/p\u003e\n"],["\u003cp\u003eThe documentation details the available versions of the \u003ccode\u003eRetryPredicate\u003c/code\u003e class, ranging from version 3.4.0 up to the latest version, 4.11.0.\u003c/p\u003e\n"],["\u003cp\u003eMethods such as \u003ccode\u003eFromErrorCodePredicate\u003c/code\u003e and \u003ccode\u003eFromErrorCodes\u003c/code\u003e allow users to create custom retry predicates based on HTTP error codes, providing flexibility in handling different error scenarios.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eRetryPredicate\u003c/code\u003e class is contained within the \u003ccode\u003eGoogle.Cloud.Storage.V1\u003c/code\u003e namespace and is part of the \u003ccode\u003eGoogle.Cloud.Storage.V1.dll\u003c/code\u003e assembly.\u003c/p\u003e\n"]]],[],null,[]]