@aws-sdk/client-ebs 3.186.0 → 3.190.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/dist-cjs/protocols/Aws_restJson1.js +1 -0
- package/dist-cjs/runtimeConfig.browser.js +9 -7
- package/dist-cjs/runtimeConfig.js +9 -7
- package/dist-es/EBS.js +26 -33
- package/dist-es/EBSClient.js +22 -28
- package/dist-es/commands/CompleteSnapshotCommand.js +21 -28
- package/dist-es/commands/GetSnapshotBlockCommand.js +21 -28
- package/dist-es/commands/ListChangedBlocksCommand.js +21 -28
- package/dist-es/commands/ListSnapshotBlocksCommand.js +21 -28
- package/dist-es/commands/PutSnapshotBlockCommand.js +21 -28
- package/dist-es/commands/StartSnapshotCommand.js +21 -28
- package/dist-es/endpoints.js +8 -8
- package/dist-es/models/EBSServiceException.js +5 -10
- package/dist-es/models/models_0.js +152 -117
- package/dist-es/pagination/ListChangedBlocksPaginator.js +25 -68
- package/dist-es/pagination/ListSnapshotBlocksPaginator.js +25 -68
- package/dist-es/protocols/Aws_restJson1.js +640 -844
- package/dist-es/runtimeConfig.browser.js +28 -12
- package/dist-es/runtimeConfig.js +32 -12
- package/dist-es/runtimeConfig.native.js +8 -5
- package/dist-es/runtimeConfig.shared.js +8 -11
- package/dist-types/EBSClient.d.ts +6 -1
- package/dist-types/commands/GetSnapshotBlockCommand.d.ts +2 -2
- package/dist-types/protocols/Aws_restJson1.d.ts +2 -2
- package/dist-types/runtimeConfig.browser.d.ts +1 -0
- package/dist-types/runtimeConfig.d.ts +1 -0
- package/dist-types/runtimeConfig.native.d.ts +1 -0
- package/dist-types/ts3.4/EBSClient.d.ts +2 -0
- package/dist-types/ts3.4/commands/GetSnapshotBlockCommand.d.ts +2 -1
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +5 -2
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +1 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +1 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -0
- package/package.json +35 -33
|
@@ -1,39 +1,32 @@
|
|
|
1
|
-
import { __extends } from "tslib";
|
|
2
1
|
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
3
2
|
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
3
|
import { StartSnapshotRequestFilterSensitiveLog, StartSnapshotResponseFilterSensitiveLog, } from "../models/models_0";
|
|
5
4
|
import { deserializeAws_restJson1StartSnapshotCommand, serializeAws_restJson1StartSnapshotCommand, } from "../protocols/Aws_restJson1";
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
_this.input = input;
|
|
11
|
-
return _this;
|
|
5
|
+
export class StartSnapshotCommand extends $Command {
|
|
6
|
+
constructor(input) {
|
|
7
|
+
super();
|
|
8
|
+
this.input = input;
|
|
12
9
|
}
|
|
13
|
-
|
|
10
|
+
resolveMiddleware(clientStack, configuration, options) {
|
|
14
11
|
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
logger
|
|
21
|
-
clientName
|
|
22
|
-
commandName
|
|
12
|
+
const stack = clientStack.concat(this.middlewareStack);
|
|
13
|
+
const { logger } = configuration;
|
|
14
|
+
const clientName = "EBSClient";
|
|
15
|
+
const commandName = "StartSnapshotCommand";
|
|
16
|
+
const handlerExecutionContext = {
|
|
17
|
+
logger,
|
|
18
|
+
clientName,
|
|
19
|
+
commandName,
|
|
23
20
|
inputFilterSensitiveLog: StartSnapshotRequestFilterSensitiveLog,
|
|
24
21
|
outputFilterSensitiveLog: StartSnapshotResponseFilterSensitiveLog,
|
|
25
22
|
};
|
|
26
|
-
|
|
27
|
-
return stack.resolve(
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
};
|
|
31
|
-
StartSnapshotCommand.prototype.serialize = function (input, context) {
|
|
23
|
+
const { requestHandler } = configuration;
|
|
24
|
+
return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
|
|
25
|
+
}
|
|
26
|
+
serialize(input, context) {
|
|
32
27
|
return serializeAws_restJson1StartSnapshotCommand(input, context);
|
|
33
|
-
}
|
|
34
|
-
|
|
28
|
+
}
|
|
29
|
+
deserialize(output, context) {
|
|
35
30
|
return deserializeAws_restJson1StartSnapshotCommand(output, context);
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
}($Command));
|
|
39
|
-
export { StartSnapshotCommand };
|
|
31
|
+
}
|
|
32
|
+
}
|
package/dist-es/endpoints.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
1
|
import { getRegionInfo } from "@aws-sdk/config-resolver";
|
|
3
|
-
|
|
2
|
+
const regionHash = {
|
|
4
3
|
"ca-central-1": {
|
|
5
4
|
variants: [
|
|
6
5
|
{
|
|
@@ -42,7 +41,7 @@ var regionHash = {
|
|
|
42
41
|
],
|
|
43
42
|
},
|
|
44
43
|
};
|
|
45
|
-
|
|
44
|
+
const partitionHash = {
|
|
46
45
|
aws: {
|
|
47
46
|
regions: [
|
|
48
47
|
"af-south-1",
|
|
@@ -167,8 +166,9 @@ var partitionHash = {
|
|
|
167
166
|
],
|
|
168
167
|
},
|
|
169
168
|
};
|
|
170
|
-
export
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
169
|
+
export const defaultRegionInfoProvider = async (region, options) => getRegionInfo(region, {
|
|
170
|
+
...options,
|
|
171
|
+
signingService: "ebs",
|
|
172
|
+
regionHash,
|
|
173
|
+
partitionHash,
|
|
174
|
+
});
|
|
@@ -1,12 +1,7 @@
|
|
|
1
|
-
import { __extends } from "tslib";
|
|
2
1
|
import { ServiceException as __ServiceException, } from "@aws-sdk/smithy-client";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
Object.setPrototypeOf(_this, EBSServiceException.prototype);
|
|
8
|
-
return _this;
|
|
2
|
+
export class EBSServiceException extends __ServiceException {
|
|
3
|
+
constructor(options) {
|
|
4
|
+
super(options);
|
|
5
|
+
Object.setPrototypeOf(this, EBSServiceException.prototype);
|
|
9
6
|
}
|
|
10
|
-
|
|
11
|
-
}(__ServiceException));
|
|
12
|
-
export { EBSServiceException };
|
|
7
|
+
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { __assign, __extends } from "tslib";
|
|
2
1
|
import { SENSITIVE_STRING } from "@aws-sdk/smithy-client";
|
|
3
2
|
import { EBSServiceException as __BaseException } from "./EBSServiceException";
|
|
4
3
|
export var AccessDeniedExceptionReason;
|
|
@@ -6,20 +5,20 @@ export var AccessDeniedExceptionReason;
|
|
|
6
5
|
AccessDeniedExceptionReason["DEPENDENCY_ACCESS_DENIED"] = "DEPENDENCY_ACCESS_DENIED";
|
|
7
6
|
AccessDeniedExceptionReason["UNAUTHORIZED_ACCOUNT"] = "UNAUTHORIZED_ACCOUNT";
|
|
8
7
|
})(AccessDeniedExceptionReason || (AccessDeniedExceptionReason = {}));
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
8
|
+
export class AccessDeniedException extends __BaseException {
|
|
9
|
+
constructor(opts) {
|
|
10
|
+
super({
|
|
11
|
+
name: "AccessDeniedException",
|
|
12
|
+
$fault: "client",
|
|
13
|
+
...opts,
|
|
14
|
+
});
|
|
15
|
+
this.name = "AccessDeniedException";
|
|
16
|
+
this.$fault = "client";
|
|
17
|
+
Object.setPrototypeOf(this, AccessDeniedException.prototype);
|
|
18
|
+
this.Message = opts.Message;
|
|
19
|
+
this.Reason = opts.Reason;
|
|
19
20
|
}
|
|
20
|
-
|
|
21
|
-
}(__BaseException));
|
|
22
|
-
export { AccessDeniedException };
|
|
21
|
+
}
|
|
23
22
|
export var ChecksumAggregationMethod;
|
|
24
23
|
(function (ChecksumAggregationMethod) {
|
|
25
24
|
ChecksumAggregationMethod["CHECKSUM_AGGREGATION_LINEAR"] = "LINEAR";
|
|
@@ -34,76 +33,76 @@ export var Status;
|
|
|
34
33
|
Status["ERROR"] = "error";
|
|
35
34
|
Status["PENDING"] = "pending";
|
|
36
35
|
})(Status || (Status = {}));
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
36
|
+
export class InternalServerException extends __BaseException {
|
|
37
|
+
constructor(opts) {
|
|
38
|
+
super({
|
|
39
|
+
name: "InternalServerException",
|
|
40
|
+
$fault: "server",
|
|
41
|
+
...opts,
|
|
42
|
+
});
|
|
43
|
+
this.name = "InternalServerException";
|
|
44
|
+
this.$fault = "server";
|
|
45
|
+
Object.setPrototypeOf(this, InternalServerException.prototype);
|
|
46
|
+
this.Message = opts.Message;
|
|
46
47
|
}
|
|
47
|
-
|
|
48
|
-
}(__BaseException));
|
|
49
|
-
export { InternalServerException };
|
|
48
|
+
}
|
|
50
49
|
export var RequestThrottledExceptionReason;
|
|
51
50
|
(function (RequestThrottledExceptionReason) {
|
|
52
51
|
RequestThrottledExceptionReason["ACCOUNT_THROTTLED"] = "ACCOUNT_THROTTLED";
|
|
53
52
|
RequestThrottledExceptionReason["DEPENDENCY_REQUEST_THROTTLED"] = "DEPENDENCY_REQUEST_THROTTLED";
|
|
54
53
|
RequestThrottledExceptionReason["RESOURCE_LEVEL_THROTTLE"] = "RESOURCE_LEVEL_THROTTLE";
|
|
55
54
|
})(RequestThrottledExceptionReason || (RequestThrottledExceptionReason = {}));
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
55
|
+
export class RequestThrottledException extends __BaseException {
|
|
56
|
+
constructor(opts) {
|
|
57
|
+
super({
|
|
58
|
+
name: "RequestThrottledException",
|
|
59
|
+
$fault: "client",
|
|
60
|
+
...opts,
|
|
61
|
+
});
|
|
62
|
+
this.name = "RequestThrottledException";
|
|
63
|
+
this.$fault = "client";
|
|
64
|
+
Object.setPrototypeOf(this, RequestThrottledException.prototype);
|
|
65
|
+
this.Message = opts.Message;
|
|
66
|
+
this.Reason = opts.Reason;
|
|
66
67
|
}
|
|
67
|
-
|
|
68
|
-
}(__BaseException));
|
|
69
|
-
export { RequestThrottledException };
|
|
68
|
+
}
|
|
70
69
|
export var ResourceNotFoundExceptionReason;
|
|
71
70
|
(function (ResourceNotFoundExceptionReason) {
|
|
72
71
|
ResourceNotFoundExceptionReason["DEPENDENCY_RESOURCE_NOT_FOUND"] = "DEPENDENCY_RESOURCE_NOT_FOUND";
|
|
73
72
|
ResourceNotFoundExceptionReason["SNAPSHOT_NOT_FOUND"] = "SNAPSHOT_NOT_FOUND";
|
|
74
73
|
})(ResourceNotFoundExceptionReason || (ResourceNotFoundExceptionReason = {}));
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
74
|
+
export class ResourceNotFoundException extends __BaseException {
|
|
75
|
+
constructor(opts) {
|
|
76
|
+
super({
|
|
77
|
+
name: "ResourceNotFoundException",
|
|
78
|
+
$fault: "client",
|
|
79
|
+
...opts,
|
|
80
|
+
});
|
|
81
|
+
this.name = "ResourceNotFoundException";
|
|
82
|
+
this.$fault = "client";
|
|
83
|
+
Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
|
|
84
|
+
this.Message = opts.Message;
|
|
85
|
+
this.Reason = opts.Reason;
|
|
85
86
|
}
|
|
86
|
-
|
|
87
|
-
}(__BaseException));
|
|
88
|
-
export { ResourceNotFoundException };
|
|
87
|
+
}
|
|
89
88
|
export var ServiceQuotaExceededExceptionReason;
|
|
90
89
|
(function (ServiceQuotaExceededExceptionReason) {
|
|
91
90
|
ServiceQuotaExceededExceptionReason["DEPENDENCY_SERVICE_QUOTA_EXCEEDED"] = "DEPENDENCY_SERVICE_QUOTA_EXCEEDED";
|
|
92
91
|
})(ServiceQuotaExceededExceptionReason || (ServiceQuotaExceededExceptionReason = {}));
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
92
|
+
export class ServiceQuotaExceededException extends __BaseException {
|
|
93
|
+
constructor(opts) {
|
|
94
|
+
super({
|
|
95
|
+
name: "ServiceQuotaExceededException",
|
|
96
|
+
$fault: "client",
|
|
97
|
+
...opts,
|
|
98
|
+
});
|
|
99
|
+
this.name = "ServiceQuotaExceededException";
|
|
100
|
+
this.$fault = "client";
|
|
101
|
+
Object.setPrototypeOf(this, ServiceQuotaExceededException.prototype);
|
|
102
|
+
this.Message = opts.Message;
|
|
103
|
+
this.Reason = opts.Reason;
|
|
103
104
|
}
|
|
104
|
-
|
|
105
|
-
}(__BaseException));
|
|
106
|
-
export { ServiceQuotaExceededException };
|
|
105
|
+
}
|
|
107
106
|
export var ValidationExceptionReason;
|
|
108
107
|
(function (ValidationExceptionReason) {
|
|
109
108
|
ValidationExceptionReason["CONFLICTING_BLOCK_UPDATE"] = "CONFLICTING_BLOCK_UPDATE";
|
|
@@ -119,58 +118,94 @@ export var ValidationExceptionReason;
|
|
|
119
118
|
ValidationExceptionReason["INVALID_VOLUME_SIZE"] = "INVALID_VOLUME_SIZE";
|
|
120
119
|
ValidationExceptionReason["UNRELATED_SNAPSHOTS"] = "UNRELATED_SNAPSHOTS";
|
|
121
120
|
})(ValidationExceptionReason || (ValidationExceptionReason = {}));
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
121
|
+
export class ValidationException extends __BaseException {
|
|
122
|
+
constructor(opts) {
|
|
123
|
+
super({
|
|
124
|
+
name: "ValidationException",
|
|
125
|
+
$fault: "client",
|
|
126
|
+
...opts,
|
|
127
|
+
});
|
|
128
|
+
this.name = "ValidationException";
|
|
129
|
+
this.$fault = "client";
|
|
130
|
+
Object.setPrototypeOf(this, ValidationException.prototype);
|
|
131
|
+
this.Message = opts.Message;
|
|
132
|
+
this.Reason = opts.Reason;
|
|
132
133
|
}
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
134
|
+
}
|
|
135
|
+
export class ConcurrentLimitExceededException extends __BaseException {
|
|
136
|
+
constructor(opts) {
|
|
137
|
+
super({
|
|
138
|
+
name: "ConcurrentLimitExceededException",
|
|
139
|
+
$fault: "client",
|
|
140
|
+
...opts,
|
|
141
|
+
});
|
|
142
|
+
this.name = "ConcurrentLimitExceededException";
|
|
143
|
+
this.$fault = "client";
|
|
144
|
+
Object.setPrototypeOf(this, ConcurrentLimitExceededException.prototype);
|
|
145
|
+
this.Message = opts.Message;
|
|
145
146
|
}
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
147
|
+
}
|
|
148
|
+
export class ConflictException extends __BaseException {
|
|
149
|
+
constructor(opts) {
|
|
150
|
+
super({
|
|
151
|
+
name: "ConflictException",
|
|
152
|
+
$fault: "client",
|
|
153
|
+
...opts,
|
|
154
|
+
});
|
|
155
|
+
this.name = "ConflictException";
|
|
156
|
+
this.$fault = "client";
|
|
157
|
+
Object.setPrototypeOf(this, ConflictException.prototype);
|
|
158
|
+
this.Message = opts.Message;
|
|
158
159
|
}
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
export
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
export
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
export
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
export
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
export
|
|
176
|
-
|
|
160
|
+
}
|
|
161
|
+
export const BlockFilterSensitiveLog = (obj) => ({
|
|
162
|
+
...obj,
|
|
163
|
+
});
|
|
164
|
+
export const ChangedBlockFilterSensitiveLog = (obj) => ({
|
|
165
|
+
...obj,
|
|
166
|
+
});
|
|
167
|
+
export const CompleteSnapshotRequestFilterSensitiveLog = (obj) => ({
|
|
168
|
+
...obj,
|
|
169
|
+
});
|
|
170
|
+
export const CompleteSnapshotResponseFilterSensitiveLog = (obj) => ({
|
|
171
|
+
...obj,
|
|
172
|
+
});
|
|
173
|
+
export const GetSnapshotBlockRequestFilterSensitiveLog = (obj) => ({
|
|
174
|
+
...obj,
|
|
175
|
+
});
|
|
176
|
+
export const GetSnapshotBlockResponseFilterSensitiveLog = (obj) => ({
|
|
177
|
+
...obj,
|
|
178
|
+
...(obj.BlockData && { BlockData: SENSITIVE_STRING }),
|
|
179
|
+
});
|
|
180
|
+
export const ListChangedBlocksRequestFilterSensitiveLog = (obj) => ({
|
|
181
|
+
...obj,
|
|
182
|
+
});
|
|
183
|
+
export const ListChangedBlocksResponseFilterSensitiveLog = (obj) => ({
|
|
184
|
+
...obj,
|
|
185
|
+
...(obj.ChangedBlocks && { ChangedBlocks: SENSITIVE_STRING }),
|
|
186
|
+
});
|
|
187
|
+
export const ListSnapshotBlocksRequestFilterSensitiveLog = (obj) => ({
|
|
188
|
+
...obj,
|
|
189
|
+
});
|
|
190
|
+
export const ListSnapshotBlocksResponseFilterSensitiveLog = (obj) => ({
|
|
191
|
+
...obj,
|
|
192
|
+
...(obj.Blocks && { Blocks: SENSITIVE_STRING }),
|
|
193
|
+
});
|
|
194
|
+
export const PutSnapshotBlockRequestFilterSensitiveLog = (obj) => ({
|
|
195
|
+
...obj,
|
|
196
|
+
...(obj.BlockData && { BlockData: SENSITIVE_STRING }),
|
|
197
|
+
});
|
|
198
|
+
export const PutSnapshotBlockResponseFilterSensitiveLog = (obj) => ({
|
|
199
|
+
...obj,
|
|
200
|
+
});
|
|
201
|
+
export const TagFilterSensitiveLog = (obj) => ({
|
|
202
|
+
...obj,
|
|
203
|
+
});
|
|
204
|
+
export const StartSnapshotRequestFilterSensitiveLog = (obj) => ({
|
|
205
|
+
...obj,
|
|
206
|
+
...(obj.KmsKeyArn && { KmsKeyArn: SENSITIVE_STRING }),
|
|
207
|
+
});
|
|
208
|
+
export const StartSnapshotResponseFilterSensitiveLog = (obj) => ({
|
|
209
|
+
...obj,
|
|
210
|
+
...(obj.KmsKeyArn && { KmsKeyArn: SENSITIVE_STRING }),
|
|
211
|
+
});
|
|
@@ -1,75 +1,32 @@
|
|
|
1
|
-
import { __asyncGenerator, __await, __awaiter, __generator, __read, __spreadArray } from "tslib";
|
|
2
1
|
import { ListChangedBlocksCommand, } from "../commands/ListChangedBlocksCommand";
|
|
3
2
|
import { EBS } from "../EBS";
|
|
4
3
|
import { EBSClient } from "../EBSClient";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
for (var _i = 2; _i < arguments.length; _i++) {
|
|
8
|
-
args[_i - 2] = arguments[_i];
|
|
9
|
-
}
|
|
10
|
-
return __awaiter(void 0, void 0, void 0, function () {
|
|
11
|
-
return __generator(this, function (_a) {
|
|
12
|
-
switch (_a.label) {
|
|
13
|
-
case 0: return [4, client.send.apply(client, __spreadArray([new ListChangedBlocksCommand(input)], __read(args), false))];
|
|
14
|
-
case 1: return [2, _a.sent()];
|
|
15
|
-
}
|
|
16
|
-
});
|
|
17
|
-
});
|
|
4
|
+
const makePagedClientRequest = async (client, input, ...args) => {
|
|
5
|
+
return await client.send(new ListChangedBlocksCommand(input), ...args);
|
|
18
6
|
};
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
for (var _i = 2; _i < arguments.length; _i++) {
|
|
22
|
-
args[_i - 2] = arguments[_i];
|
|
23
|
-
}
|
|
24
|
-
return __awaiter(void 0, void 0, void 0, function () {
|
|
25
|
-
return __generator(this, function (_a) {
|
|
26
|
-
switch (_a.label) {
|
|
27
|
-
case 0: return [4, client.listChangedBlocks.apply(client, __spreadArray([input], __read(args), false))];
|
|
28
|
-
case 1: return [2, _a.sent()];
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
});
|
|
7
|
+
const makePagedRequest = async (client, input, ...args) => {
|
|
8
|
+
return await client.listChangedBlocks(input, ...args);
|
|
32
9
|
};
|
|
33
|
-
export function paginateListChangedBlocks(config, input) {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
10
|
+
export async function* paginateListChangedBlocks(config, input, ...additionalArguments) {
|
|
11
|
+
let token = config.startingToken || undefined;
|
|
12
|
+
let hasNext = true;
|
|
13
|
+
let page;
|
|
14
|
+
while (hasNext) {
|
|
15
|
+
input.NextToken = token;
|
|
16
|
+
input["MaxResults"] = config.pageSize;
|
|
17
|
+
if (config.client instanceof EBS) {
|
|
18
|
+
page = await makePagedRequest(config.client, input, ...additionalArguments);
|
|
19
|
+
}
|
|
20
|
+
else if (config.client instanceof EBSClient) {
|
|
21
|
+
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
throw new Error("Invalid client, expected EBS | EBSClient");
|
|
25
|
+
}
|
|
26
|
+
yield page;
|
|
27
|
+
const prevToken = token;
|
|
28
|
+
token = page.NextToken;
|
|
29
|
+
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
37
30
|
}
|
|
38
|
-
return
|
|
39
|
-
var token, hasNext, page, prevToken;
|
|
40
|
-
return __generator(this, function (_a) {
|
|
41
|
-
switch (_a.label) {
|
|
42
|
-
case 0:
|
|
43
|
-
token = config.startingToken || undefined;
|
|
44
|
-
hasNext = true;
|
|
45
|
-
_a.label = 1;
|
|
46
|
-
case 1:
|
|
47
|
-
if (!hasNext) return [3, 9];
|
|
48
|
-
input.NextToken = token;
|
|
49
|
-
input["MaxResults"] = config.pageSize;
|
|
50
|
-
if (!(config.client instanceof EBS)) return [3, 3];
|
|
51
|
-
return [4, __await(makePagedRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
|
|
52
|
-
case 2:
|
|
53
|
-
page = _a.sent();
|
|
54
|
-
return [3, 6];
|
|
55
|
-
case 3:
|
|
56
|
-
if (!(config.client instanceof EBSClient)) return [3, 5];
|
|
57
|
-
return [4, __await(makePagedClientRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
|
|
58
|
-
case 4:
|
|
59
|
-
page = _a.sent();
|
|
60
|
-
return [3, 6];
|
|
61
|
-
case 5: throw new Error("Invalid client, expected EBS | EBSClient");
|
|
62
|
-
case 6: return [4, __await(page)];
|
|
63
|
-
case 7: return [4, _a.sent()];
|
|
64
|
-
case 8:
|
|
65
|
-
_a.sent();
|
|
66
|
-
prevToken = token;
|
|
67
|
-
token = page.NextToken;
|
|
68
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
69
|
-
return [3, 1];
|
|
70
|
-
case 9: return [4, __await(undefined)];
|
|
71
|
-
case 10: return [2, _a.sent()];
|
|
72
|
-
}
|
|
73
|
-
});
|
|
74
|
-
});
|
|
31
|
+
return undefined;
|
|
75
32
|
}
|
|
@@ -1,75 +1,32 @@
|
|
|
1
|
-
import { __asyncGenerator, __await, __awaiter, __generator, __read, __spreadArray } from "tslib";
|
|
2
1
|
import { ListSnapshotBlocksCommand, } from "../commands/ListSnapshotBlocksCommand";
|
|
3
2
|
import { EBS } from "../EBS";
|
|
4
3
|
import { EBSClient } from "../EBSClient";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
for (var _i = 2; _i < arguments.length; _i++) {
|
|
8
|
-
args[_i - 2] = arguments[_i];
|
|
9
|
-
}
|
|
10
|
-
return __awaiter(void 0, void 0, void 0, function () {
|
|
11
|
-
return __generator(this, function (_a) {
|
|
12
|
-
switch (_a.label) {
|
|
13
|
-
case 0: return [4, client.send.apply(client, __spreadArray([new ListSnapshotBlocksCommand(input)], __read(args), false))];
|
|
14
|
-
case 1: return [2, _a.sent()];
|
|
15
|
-
}
|
|
16
|
-
});
|
|
17
|
-
});
|
|
4
|
+
const makePagedClientRequest = async (client, input, ...args) => {
|
|
5
|
+
return await client.send(new ListSnapshotBlocksCommand(input), ...args);
|
|
18
6
|
};
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
for (var _i = 2; _i < arguments.length; _i++) {
|
|
22
|
-
args[_i - 2] = arguments[_i];
|
|
23
|
-
}
|
|
24
|
-
return __awaiter(void 0, void 0, void 0, function () {
|
|
25
|
-
return __generator(this, function (_a) {
|
|
26
|
-
switch (_a.label) {
|
|
27
|
-
case 0: return [4, client.listSnapshotBlocks.apply(client, __spreadArray([input], __read(args), false))];
|
|
28
|
-
case 1: return [2, _a.sent()];
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
});
|
|
7
|
+
const makePagedRequest = async (client, input, ...args) => {
|
|
8
|
+
return await client.listSnapshotBlocks(input, ...args);
|
|
32
9
|
};
|
|
33
|
-
export function paginateListSnapshotBlocks(config, input) {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
10
|
+
export async function* paginateListSnapshotBlocks(config, input, ...additionalArguments) {
|
|
11
|
+
let token = config.startingToken || undefined;
|
|
12
|
+
let hasNext = true;
|
|
13
|
+
let page;
|
|
14
|
+
while (hasNext) {
|
|
15
|
+
input.NextToken = token;
|
|
16
|
+
input["MaxResults"] = config.pageSize;
|
|
17
|
+
if (config.client instanceof EBS) {
|
|
18
|
+
page = await makePagedRequest(config.client, input, ...additionalArguments);
|
|
19
|
+
}
|
|
20
|
+
else if (config.client instanceof EBSClient) {
|
|
21
|
+
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
throw new Error("Invalid client, expected EBS | EBSClient");
|
|
25
|
+
}
|
|
26
|
+
yield page;
|
|
27
|
+
const prevToken = token;
|
|
28
|
+
token = page.NextToken;
|
|
29
|
+
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
37
30
|
}
|
|
38
|
-
return
|
|
39
|
-
var token, hasNext, page, prevToken;
|
|
40
|
-
return __generator(this, function (_a) {
|
|
41
|
-
switch (_a.label) {
|
|
42
|
-
case 0:
|
|
43
|
-
token = config.startingToken || undefined;
|
|
44
|
-
hasNext = true;
|
|
45
|
-
_a.label = 1;
|
|
46
|
-
case 1:
|
|
47
|
-
if (!hasNext) return [3, 9];
|
|
48
|
-
input.NextToken = token;
|
|
49
|
-
input["MaxResults"] = config.pageSize;
|
|
50
|
-
if (!(config.client instanceof EBS)) return [3, 3];
|
|
51
|
-
return [4, __await(makePagedRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
|
|
52
|
-
case 2:
|
|
53
|
-
page = _a.sent();
|
|
54
|
-
return [3, 6];
|
|
55
|
-
case 3:
|
|
56
|
-
if (!(config.client instanceof EBSClient)) return [3, 5];
|
|
57
|
-
return [4, __await(makePagedClientRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
|
|
58
|
-
case 4:
|
|
59
|
-
page = _a.sent();
|
|
60
|
-
return [3, 6];
|
|
61
|
-
case 5: throw new Error("Invalid client, expected EBS | EBSClient");
|
|
62
|
-
case 6: return [4, __await(page)];
|
|
63
|
-
case 7: return [4, _a.sent()];
|
|
64
|
-
case 8:
|
|
65
|
-
_a.sent();
|
|
66
|
-
prevToken = token;
|
|
67
|
-
token = page.NextToken;
|
|
68
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
69
|
-
return [3, 1];
|
|
70
|
-
case 9: return [4, __await(undefined)];
|
|
71
|
-
case 10: return [2, _a.sent()];
|
|
72
|
-
}
|
|
73
|
-
});
|
|
74
|
-
});
|
|
31
|
+
return undefined;
|
|
75
32
|
}
|