fix: 修复配额说明重复和undefined问题
- 在editStorageForm中初始化oss_storage_quota_value和oss_quota_unit - 删除重复的旧配额说明块,保留新的当前配额设置显示 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
78
backend/node_modules/@smithy/util-retry/README.md
generated
vendored
Normal file
78
backend/node_modules/@smithy/util-retry/README.md
generated
vendored
Normal file
@@ -0,0 +1,78 @@
|
||||
# @smithy/util-retry
|
||||
|
||||
[](https://www.npmjs.com/package/@smithy/util-retry)
|
||||
[](https://www.npmjs.com/package/@smithy/util-retry)
|
||||
|
||||
This package provides shared utilities for retries.
|
||||
|
||||
## Usage
|
||||
|
||||
### Default
|
||||
|
||||
By default, each client already has a default retry strategy. The default retry count is 3, and
|
||||
only retryable errors will be retried.
|
||||
|
||||
[AWS Documentation: Retry behavior](https://docs.aws.amazon.com/sdkref/latest/guide/feature-retry-behavior.html).
|
||||
|
||||
```js
|
||||
import { S3Client } from "@aws-sdk/client-s3";
|
||||
|
||||
const client = new S3Client({}); // default retry strategy included.
|
||||
```
|
||||
|
||||
### MaxAttempts
|
||||
|
||||
If you want to change the number of attempts, you can provide `maxAttempts` configuration during client creation.
|
||||
|
||||
```js
|
||||
import { S3Client } from "@aws-sdk/client-s3";
|
||||
|
||||
const client = new S3Client({ maxAttempts: 4 });
|
||||
```
|
||||
|
||||
This is recommended because the `StandardRetryStrategy` includes backoff calculation,
|
||||
deciding whether an error should be retried, and a retry token counter.
|
||||
|
||||
### MaxAttempts and BackoffComputation
|
||||
|
||||
If you want to change the number of attempts and use a custom delay
|
||||
computation, you can use the `ConfiguredRetryStrategy` from `@smithy/util-retry`.
|
||||
|
||||
```js
|
||||
import { S3Client } from "@aws-sdk/client-s3";
|
||||
import { ConfiguredRetryStrategy } from "@smithy/util-retry";
|
||||
|
||||
const client = new S3Client({
|
||||
retryStrategy: new ConfiguredRetryStrategy(
|
||||
4, // max attempts.
|
||||
(attempt: number) => 100 + attempt * 1000 // backoff function.
|
||||
),
|
||||
});
|
||||
```
|
||||
|
||||
This example sets the backoff at 100ms plus 1s per attempt.
|
||||
|
||||
### MaxAttempts and RetryStrategy
|
||||
|
||||
If you provide both `maxAttempts` and `retryStrategy`, the `retryStrategy` will
|
||||
get precedence as it's more specific.
|
||||
|
||||
```js
|
||||
import { S3Client } from "@aws-sdk/client-s3";
|
||||
import { ConfiguredRetryStrategy } from "@smithy/util-retry";
|
||||
|
||||
const client = new S3Client({
|
||||
maxAttempts: 2, // ignored.
|
||||
retryStrategy: new ConfiguredRetryStrategy(
|
||||
4, // used.
|
||||
(attempt: number) => 100 + attempt * 1000 // backoff function.
|
||||
),
|
||||
});
|
||||
```
|
||||
|
||||
### Further customization
|
||||
|
||||
You can implement the `RetryStrategyV2` interface.
|
||||
|
||||
Source: https://github.com/smithy-lang/smithy-typescript/blob/main/packages/types/src/retry.ts
|
||||
API Docs: https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-smithy-types/Interface/RetryStrategyV2/
|
||||
Reference in New Issue
Block a user