Skip to content

Commit 614d71c

Browse files
committed
chore: refactor schemas
1 parent 753779c commit 614d71c

File tree

149 files changed

+11075
-5488
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

149 files changed

+11075
-5488
lines changed

clients/client-dynamodb/src/DynamoDBClient.ts

+2
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ import {
3030
getHttpAuthSchemeEndpointRuleSetPlugin,
3131
getHttpSigningPlugin,
3232
} from "@smithy/core";
33+
import { getSchemaSerdePlugin } from "@smithy/core/schema";
3334
import { getContentLengthPlugin } from "@smithy/middleware-content-length";
3435
import { EndpointInputConfig, EndpointResolvedConfig, resolveEndpointConfig } from "@smithy/middleware-endpoint";
3536
import { getRetryPlugin, resolveRetryConfig, RetryInputConfig, RetryResolvedConfig } from "@smithy/middleware-retry";
@@ -571,6 +572,7 @@ export class DynamoDBClient extends __Client<
571572
});
572573
const _config_10 = resolveRuntimeExtensions(_config_9, configuration?.extensions || []);
573574
this.config = _config_10;
575+
this.middlewareStack.use(getSchemaSerdePlugin(this.config));
574576
this.middlewareStack.use(getUserAgentPlugin(this.config));
575577
this.middlewareStack.use(getRetryPlugin(this.config));
576578
this.middlewareStack.use(getContentLengthPlugin(this.config));

clients/client-dynamodb/src/commands/BatchExecuteStatementCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { BatchExecuteStatementInput, BatchExecuteStatementOutput } from "../models/models_0";
10-
import { de_BatchExecuteStatementCommand, se_BatchExecuteStatementCommand } from "../protocols/Aws_json1_0";
9+
import { BatchExecuteStatement } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -224,16 +223,12 @@ export class BatchExecuteStatementCommand extends $Command
224223
>()
225224
.ep(commonParams)
226225
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
227-
return [
228-
getSerdePlugin(config, this.serialize, this.deserialize),
229-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
230-
];
226+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
231227
})
232228
.s("DynamoDB_20120810", "BatchExecuteStatement", {})
233229
.n("DynamoDBClient", "BatchExecuteStatementCommand")
234230
.f(void 0, void 0)
235-
.ser(se_BatchExecuteStatementCommand)
236-
.de(de_BatchExecuteStatementCommand)
231+
.sc(BatchExecuteStatement)
237232
.build() {
238233
/** @internal type navigation helper, not in runtime. */
239234
protected declare static __types: {

clients/client-dynamodb/src/commands/BatchGetItemCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { BatchGetItemInput, BatchGetItemOutput } from "../models/models_0";
10-
import { de_BatchGetItemCommand, se_BatchGetItemCommand } from "../protocols/Aws_json1_0";
9+
import { BatchGetItem } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -351,16 +350,12 @@ export class BatchGetItemCommand extends $Command
351350
ResourceArnList: { type: "operationContextParams", get: (input?: any) => Object.keys(input?.RequestItems ?? {}) },
352351
})
353352
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
354-
return [
355-
getSerdePlugin(config, this.serialize, this.deserialize),
356-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
357-
];
353+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
358354
})
359355
.s("DynamoDB_20120810", "BatchGetItem", {})
360356
.n("DynamoDBClient", "BatchGetItemCommand")
361357
.f(void 0, void 0)
362-
.ser(se_BatchGetItemCommand)
363-
.de(de_BatchGetItemCommand)
358+
.sc(BatchGetItem)
364359
.build() {
365360
/** @internal type navigation helper, not in runtime. */
366361
protected declare static __types: {

clients/client-dynamodb/src/commands/BatchWriteItemCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { BatchWriteItemInput, BatchWriteItemOutput } from "../models/models_0";
10-
import { de_BatchWriteItemCommand, se_BatchWriteItemCommand } from "../protocols/Aws_json1_0";
9+
import { BatchWriteItem } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -400,16 +399,12 @@ export class BatchWriteItemCommand extends $Command
400399
ResourceArnList: { type: "operationContextParams", get: (input?: any) => Object.keys(input?.RequestItems ?? {}) },
401400
})
402401
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
403-
return [
404-
getSerdePlugin(config, this.serialize, this.deserialize),
405-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
406-
];
402+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
407403
})
408404
.s("DynamoDB_20120810", "BatchWriteItem", {})
409405
.n("DynamoDBClient", "BatchWriteItemCommand")
410406
.f(void 0, void 0)
411-
.ser(se_BatchWriteItemCommand)
412-
.de(de_BatchWriteItemCommand)
407+
.sc(BatchWriteItem)
413408
.build() {
414409
/** @internal type navigation helper, not in runtime. */
415410
protected declare static __types: {

clients/client-dynamodb/src/commands/CreateBackupCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { CreateBackupInput, CreateBackupOutput } from "../models/models_0";
10-
import { de_CreateBackupCommand, se_CreateBackupCommand } from "../protocols/Aws_json1_0";
9+
import { CreateBackup } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -145,16 +144,12 @@ export class CreateBackupCommand extends $Command
145144
ResourceArn: { type: "contextParams", name: "TableName" },
146145
})
147146
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
148-
return [
149-
getSerdePlugin(config, this.serialize, this.deserialize),
150-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
151-
];
147+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
152148
})
153149
.s("DynamoDB_20120810", "CreateBackup", {})
154150
.n("DynamoDBClient", "CreateBackupCommand")
155151
.f(void 0, void 0)
156-
.ser(se_CreateBackupCommand)
157-
.de(de_CreateBackupCommand)
152+
.sc(CreateBackup)
158153
.build() {
159154
/** @internal type navigation helper, not in runtime. */
160155
protected declare static __types: {

clients/client-dynamodb/src/commands/CreateGlobalTableCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { CreateGlobalTableInput, CreateGlobalTableOutput } from "../models/models_0";
10-
import { de_CreateGlobalTableCommand, se_CreateGlobalTableCommand } from "../protocols/Aws_json1_0";
9+
import { CreateGlobalTable } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -204,16 +203,12 @@ export class CreateGlobalTableCommand extends $Command
204203
ResourceArn: { type: "contextParams", name: "GlobalTableName" },
205204
})
206205
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
207-
return [
208-
getSerdePlugin(config, this.serialize, this.deserialize),
209-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
210-
];
206+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
211207
})
212208
.s("DynamoDB_20120810", "CreateGlobalTable", {})
213209
.n("DynamoDBClient", "CreateGlobalTableCommand")
214210
.f(void 0, void 0)
215-
.ser(se_CreateGlobalTableCommand)
216-
.de(de_CreateGlobalTableCommand)
211+
.sc(CreateGlobalTable)
217212
.build() {
218213
/** @internal type navigation helper, not in runtime. */
219214
protected declare static __types: {

clients/client-dynamodb/src/commands/CreateTableCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { CreateTableInput, CreateTableOutput } from "../models/models_0";
10-
import { de_CreateTableCommand, se_CreateTableCommand } from "../protocols/Aws_json1_0";
9+
import { CreateTable } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -377,16 +376,12 @@ export class CreateTableCommand extends $Command
377376
ResourceArn: { type: "contextParams", name: "TableName" },
378377
})
379378
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
380-
return [
381-
getSerdePlugin(config, this.serialize, this.deserialize),
382-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
383-
];
379+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
384380
})
385381
.s("DynamoDB_20120810", "CreateTable", {})
386382
.n("DynamoDBClient", "CreateTableCommand")
387383
.f(void 0, void 0)
388-
.ser(se_CreateTableCommand)
389-
.de(de_CreateTableCommand)
384+
.sc(CreateTable)
390385
.build() {
391386
/** @internal type navigation helper, not in runtime. */
392387
protected declare static __types: {

clients/client-dynamodb/src/commands/DeleteBackupCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { DeleteBackupInput, DeleteBackupOutput } from "../models/models_0";
10-
import { de_DeleteBackupCommand, se_DeleteBackupCommand } from "../protocols/Aws_json1_0";
9+
import { DeleteBackup } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -192,16 +191,12 @@ export class DeleteBackupCommand extends $Command
192191
ResourceArn: { type: "contextParams", name: "BackupArn" },
193192
})
194193
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
195-
return [
196-
getSerdePlugin(config, this.serialize, this.deserialize),
197-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
198-
];
194+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
199195
})
200196
.s("DynamoDB_20120810", "DeleteBackup", {})
201197
.n("DynamoDBClient", "DeleteBackupCommand")
202198
.f(void 0, void 0)
203-
.ser(se_DeleteBackupCommand)
204-
.de(de_DeleteBackupCommand)
199+
.sc(DeleteBackup)
205200
.build() {
206201
/** @internal type navigation helper, not in runtime. */
207202
protected declare static __types: {

clients/client-dynamodb/src/commands/DeleteItemCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { DeleteItemInput, DeleteItemOutput } from "../models/models_0";
10-
import { de_DeleteItemCommand, se_DeleteItemCommand } from "../protocols/Aws_json1_0";
9+
import { DeleteItem } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -285,16 +284,12 @@ export class DeleteItemCommand extends $Command
285284
ResourceArn: { type: "contextParams", name: "TableName" },
286285
})
287286
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
288-
return [
289-
getSerdePlugin(config, this.serialize, this.deserialize),
290-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
291-
];
287+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
292288
})
293289
.s("DynamoDB_20120810", "DeleteItem", {})
294290
.n("DynamoDBClient", "DeleteItemCommand")
295291
.f(void 0, void 0)
296-
.ser(se_DeleteItemCommand)
297-
.de(de_DeleteItemCommand)
292+
.sc(DeleteItem)
298293
.build() {
299294
/** @internal type navigation helper, not in runtime. */
300295
protected declare static __types: {

clients/client-dynamodb/src/commands/DeleteResourcePolicyCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { DeleteResourcePolicyInput, DeleteResourcePolicyOutput } from "../models/models_0";
10-
import { de_DeleteResourcePolicyCommand, se_DeleteResourcePolicyCommand } from "../protocols/Aws_json1_0";
9+
import { DeleteResourcePolicy } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -137,16 +136,12 @@ export class DeleteResourcePolicyCommand extends $Command
137136
ResourceArn: { type: "contextParams", name: "ResourceArn" },
138137
})
139138
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
140-
return [
141-
getSerdePlugin(config, this.serialize, this.deserialize),
142-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
143-
];
139+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
144140
})
145141
.s("DynamoDB_20120810", "DeleteResourcePolicy", {})
146142
.n("DynamoDBClient", "DeleteResourcePolicyCommand")
147143
.f(void 0, void 0)
148-
.ser(se_DeleteResourcePolicyCommand)
149-
.de(de_DeleteResourcePolicyCommand)
144+
.sc(DeleteResourcePolicy)
150145
.build() {
151146
/** @internal type navigation helper, not in runtime. */
152147
protected declare static __types: {

clients/client-dynamodb/src/commands/DeleteTableCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { DeleteTableInput, DeleteTableOutput } from "../models/models_0";
10-
import { de_DeleteTableCommand, se_DeleteTableCommand } from "../protocols/Aws_json1_0";
9+
import { DeleteTable } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -327,16 +326,12 @@ export class DeleteTableCommand extends $Command
327326
ResourceArn: { type: "contextParams", name: "TableName" },
328327
})
329328
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
330-
return [
331-
getSerdePlugin(config, this.serialize, this.deserialize),
332-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
333-
];
329+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
334330
})
335331
.s("DynamoDB_20120810", "DeleteTable", {})
336332
.n("DynamoDBClient", "DeleteTableCommand")
337333
.f(void 0, void 0)
338-
.ser(se_DeleteTableCommand)
339-
.de(de_DeleteTableCommand)
334+
.sc(DeleteTable)
340335
.build() {
341336
/** @internal type navigation helper, not in runtime. */
342337
protected declare static __types: {

clients/client-dynamodb/src/commands/DescribeBackupCommand.ts

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// smithy-typescript generated code
22
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3-
import { getSerdePlugin } from "@smithy/middleware-serde";
43
import { Command as $Command } from "@smithy/smithy-client";
54
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
65

76
import { DynamoDBClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../DynamoDBClient";
87
import { commonParams } from "../endpoint/EndpointParameters";
98
import { DescribeBackupInput, DescribeBackupOutput } from "../models/models_0";
10-
import { de_DescribeBackupCommand, se_DescribeBackupCommand } from "../protocols/Aws_json1_0";
9+
import { DescribeBackup } from "../schemas/com.amazonaws.dynamodb";
1110

1211
/**
1312
* @public
@@ -172,16 +171,12 @@ export class DescribeBackupCommand extends $Command
172171
ResourceArn: { type: "contextParams", name: "BackupArn" },
173172
})
174173
.m(function (this: any, Command: any, cs: any, config: DynamoDBClientResolvedConfig, o: any) {
175-
return [
176-
getSerdePlugin(config, this.serialize, this.deserialize),
177-
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
178-
];
174+
return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
179175
})
180176
.s("DynamoDB_20120810", "DescribeBackup", {})
181177
.n("DynamoDBClient", "DescribeBackupCommand")
182178
.f(void 0, void 0)
183-
.ser(se_DescribeBackupCommand)
184-
.de(de_DescribeBackupCommand)
179+
.sc(DescribeBackup)
185180
.build() {
186181
/** @internal type navigation helper, not in runtime. */
187182
protected declare static __types: {

0 commit comments

Comments
 (0)