@aws-sdk/client-sagemaker-edge 3.121.0 → 3.130.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 CHANGED
@@ -3,6 +3,33 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.130.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.129.0...v3.130.0) (2022-07-14)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **codegen:** fix error code parsing when it's a number ([#3371](https://github.com/aws/aws-sdk-js-v3/issues/3371)) ([c2d8522](https://github.com/aws/aws-sdk-js-v3/commit/c2d852279a3d23958521a6ceb4f4c642b0cb1848))
12
+
13
+
14
+
15
+
16
+
17
+ # [3.128.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.127.0...v3.128.0) (2022-07-12)
18
+
19
+ **Note:** Version bump only for package @aws-sdk/client-sagemaker-edge
20
+
21
+
22
+
23
+
24
+
25
+ # [3.127.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.126.0...v3.127.0) (2022-07-11)
26
+
27
+ **Note:** Version bump only for package @aws-sdk/client-sagemaker-edge
28
+
29
+
30
+
31
+
32
+
6
33
  # [3.121.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.120.0...v3.121.0) (2022-06-30)
7
34
 
8
35
 
@@ -13,9 +13,8 @@ const serializeAws_restJson1GetDeviceRegistrationCommand = async (input, context
13
13
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetDeviceRegistration";
14
14
  let body;
15
15
  body = JSON.stringify({
16
- ...(input.DeviceFleetName !== undefined &&
17
- input.DeviceFleetName !== null && { DeviceFleetName: input.DeviceFleetName }),
18
- ...(input.DeviceName !== undefined && input.DeviceName !== null && { DeviceName: input.DeviceName }),
16
+ ...(input.DeviceFleetName != null && { DeviceFleetName: input.DeviceFleetName }),
17
+ ...(input.DeviceName != null && { DeviceName: input.DeviceName }),
19
18
  });
20
19
  return new protocol_http_1.HttpRequest({
21
20
  protocol,
@@ -36,14 +35,11 @@ const serializeAws_restJson1SendHeartbeatCommand = async (input, context) => {
36
35
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/SendHeartbeat";
37
36
  let body;
38
37
  body = JSON.stringify({
39
- ...(input.AgentMetrics !== undefined &&
40
- input.AgentMetrics !== null && { AgentMetrics: serializeAws_restJson1EdgeMetrics(input.AgentMetrics, context) }),
41
- ...(input.AgentVersion !== undefined && input.AgentVersion !== null && { AgentVersion: input.AgentVersion }),
42
- ...(input.DeviceFleetName !== undefined &&
43
- input.DeviceFleetName !== null && { DeviceFleetName: input.DeviceFleetName }),
44
- ...(input.DeviceName !== undefined && input.DeviceName !== null && { DeviceName: input.DeviceName }),
45
- ...(input.Models !== undefined &&
46
- input.Models !== null && { Models: serializeAws_restJson1Models(input.Models, context) }),
38
+ ...(input.AgentMetrics != null && { AgentMetrics: serializeAws_restJson1EdgeMetrics(input.AgentMetrics, context) }),
39
+ ...(input.AgentVersion != null && { AgentVersion: input.AgentVersion }),
40
+ ...(input.DeviceFleetName != null && { DeviceFleetName: input.DeviceFleetName }),
41
+ ...(input.DeviceName != null && { DeviceName: input.DeviceName }),
42
+ ...(input.Models != null && { Models: serializeAws_restJson1Models(input.Models, context) }),
47
43
  });
48
44
  return new protocol_http_1.HttpRequest({
49
45
  protocol,
@@ -146,11 +142,10 @@ const deserializeAws_restJson1InternalServiceExceptionResponse = async (parsedOu
146
142
  };
147
143
  const serializeAws_restJson1EdgeMetric = (input, context) => {
148
144
  return {
149
- ...(input.Dimension !== undefined && input.Dimension !== null && { Dimension: input.Dimension }),
150
- ...(input.MetricName !== undefined && input.MetricName !== null && { MetricName: input.MetricName }),
151
- ...(input.Timestamp !== undefined &&
152
- input.Timestamp !== null && { Timestamp: Math.round(input.Timestamp.getTime() / 1000) }),
153
- ...(input.Value !== undefined && input.Value !== null && { Value: (0, smithy_client_1.serializeFloat)(input.Value) }),
145
+ ...(input.Dimension != null && { Dimension: input.Dimension }),
146
+ ...(input.MetricName != null && { MetricName: input.MetricName }),
147
+ ...(input.Timestamp != null && { Timestamp: Math.round(input.Timestamp.getTime() / 1000) }),
148
+ ...(input.Value != null && { Value: (0, smithy_client_1.serializeFloat)(input.Value) }),
154
149
  };
155
150
  };
156
151
  const serializeAws_restJson1EdgeMetrics = (input, context) => {
@@ -165,14 +160,11 @@ const serializeAws_restJson1EdgeMetrics = (input, context) => {
165
160
  };
166
161
  const serializeAws_restJson1Model = (input, context) => {
167
162
  return {
168
- ...(input.LatestInference !== undefined &&
169
- input.LatestInference !== null && { LatestInference: Math.round(input.LatestInference.getTime() / 1000) }),
170
- ...(input.LatestSampleTime !== undefined &&
171
- input.LatestSampleTime !== null && { LatestSampleTime: Math.round(input.LatestSampleTime.getTime() / 1000) }),
172
- ...(input.ModelMetrics !== undefined &&
173
- input.ModelMetrics !== null && { ModelMetrics: serializeAws_restJson1EdgeMetrics(input.ModelMetrics, context) }),
174
- ...(input.ModelName !== undefined && input.ModelName !== null && { ModelName: input.ModelName }),
175
- ...(input.ModelVersion !== undefined && input.ModelVersion !== null && { ModelVersion: input.ModelVersion }),
163
+ ...(input.LatestInference != null && { LatestInference: Math.round(input.LatestInference.getTime() / 1000) }),
164
+ ...(input.LatestSampleTime != null && { LatestSampleTime: Math.round(input.LatestSampleTime.getTime() / 1000) }),
165
+ ...(input.ModelMetrics != null && { ModelMetrics: serializeAws_restJson1EdgeMetrics(input.ModelMetrics, context) }),
166
+ ...(input.ModelName != null && { ModelName: input.ModelName }),
167
+ ...(input.ModelVersion != null && { ModelVersion: input.ModelVersion }),
176
168
  };
177
169
  };
178
170
  const serializeAws_restJson1Models = (input, context) => {
@@ -216,6 +208,9 @@ const loadRestJsonErrorCode = (output, data) => {
216
208
  const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
217
209
  const sanitizeErrorCode = (rawValue) => {
218
210
  let cleanValue = rawValue;
211
+ if (typeof cleanValue === "number") {
212
+ cleanValue = cleanValue.toString();
213
+ }
219
214
  if (cleanValue.indexOf(":") >= 0) {
220
215
  cleanValue = cleanValue.split(":")[0];
221
216
  }
@@ -14,8 +14,7 @@ export var serializeAws_restJson1GetDeviceRegistrationCommand = function (input,
14
14
  "content-type": "application/json",
15
15
  };
16
16
  resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/GetDeviceRegistration";
17
- body = JSON.stringify(__assign(__assign({}, (input.DeviceFleetName !== undefined &&
18
- input.DeviceFleetName !== null && { DeviceFleetName: input.DeviceFleetName })), (input.DeviceName !== undefined && input.DeviceName !== null && { DeviceName: input.DeviceName })));
17
+ body = JSON.stringify(__assign(__assign({}, (input.DeviceFleetName != null && { DeviceFleetName: input.DeviceFleetName })), (input.DeviceName != null && { DeviceName: input.DeviceName })));
19
18
  return [2, new __HttpRequest({
20
19
  protocol: protocol,
21
20
  hostname: hostname,
@@ -39,10 +38,7 @@ export var serializeAws_restJson1SendHeartbeatCommand = function (input, context
39
38
  "content-type": "application/json",
40
39
  };
41
40
  resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/SendHeartbeat";
42
- body = JSON.stringify(__assign(__assign(__assign(__assign(__assign({}, (input.AgentMetrics !== undefined &&
43
- input.AgentMetrics !== null && { AgentMetrics: serializeAws_restJson1EdgeMetrics(input.AgentMetrics, context) })), (input.AgentVersion !== undefined && input.AgentVersion !== null && { AgentVersion: input.AgentVersion })), (input.DeviceFleetName !== undefined &&
44
- input.DeviceFleetName !== null && { DeviceFleetName: input.DeviceFleetName })), (input.DeviceName !== undefined && input.DeviceName !== null && { DeviceName: input.DeviceName })), (input.Models !== undefined &&
45
- input.Models !== null && { Models: serializeAws_restJson1Models(input.Models, context) })));
41
+ body = JSON.stringify(__assign(__assign(__assign(__assign(__assign({}, (input.AgentMetrics != null && { AgentMetrics: serializeAws_restJson1EdgeMetrics(input.AgentMetrics, context) })), (input.AgentVersion != null && { AgentVersion: input.AgentVersion })), (input.DeviceFleetName != null && { DeviceFleetName: input.DeviceFleetName })), (input.DeviceName != null && { DeviceName: input.DeviceName })), (input.Models != null && { Models: serializeAws_restJson1Models(input.Models, context) })));
46
42
  return [2, new __HttpRequest({
47
43
  protocol: protocol,
48
44
  hostname: hostname,
@@ -180,8 +176,7 @@ var deserializeAws_restJson1InternalServiceExceptionResponse = function (parsedO
180
176
  });
181
177
  }); };
182
178
  var serializeAws_restJson1EdgeMetric = function (input, context) {
183
- return __assign(__assign(__assign(__assign({}, (input.Dimension !== undefined && input.Dimension !== null && { Dimension: input.Dimension })), (input.MetricName !== undefined && input.MetricName !== null && { MetricName: input.MetricName })), (input.Timestamp !== undefined &&
184
- input.Timestamp !== null && { Timestamp: Math.round(input.Timestamp.getTime() / 1000) })), (input.Value !== undefined && input.Value !== null && { Value: __serializeFloat(input.Value) }));
179
+ return __assign(__assign(__assign(__assign({}, (input.Dimension != null && { Dimension: input.Dimension })), (input.MetricName != null && { MetricName: input.MetricName })), (input.Timestamp != null && { Timestamp: Math.round(input.Timestamp.getTime() / 1000) })), (input.Value != null && { Value: __serializeFloat(input.Value) }));
185
180
  };
186
181
  var serializeAws_restJson1EdgeMetrics = function (input, context) {
187
182
  return input
@@ -194,10 +189,7 @@ var serializeAws_restJson1EdgeMetrics = function (input, context) {
194
189
  });
195
190
  };
196
191
  var serializeAws_restJson1Model = function (input, context) {
197
- return __assign(__assign(__assign(__assign(__assign({}, (input.LatestInference !== undefined &&
198
- input.LatestInference !== null && { LatestInference: Math.round(input.LatestInference.getTime() / 1000) })), (input.LatestSampleTime !== undefined &&
199
- input.LatestSampleTime !== null && { LatestSampleTime: Math.round(input.LatestSampleTime.getTime() / 1000) })), (input.ModelMetrics !== undefined &&
200
- input.ModelMetrics !== null && { ModelMetrics: serializeAws_restJson1EdgeMetrics(input.ModelMetrics, context) })), (input.ModelName !== undefined && input.ModelName !== null && { ModelName: input.ModelName })), (input.ModelVersion !== undefined && input.ModelVersion !== null && { ModelVersion: input.ModelVersion }));
192
+ return __assign(__assign(__assign(__assign(__assign({}, (input.LatestInference != null && { LatestInference: Math.round(input.LatestInference.getTime() / 1000) })), (input.LatestSampleTime != null && { LatestSampleTime: Math.round(input.LatestSampleTime.getTime() / 1000) })), (input.ModelMetrics != null && { ModelMetrics: serializeAws_restJson1EdgeMetrics(input.ModelMetrics, context) })), (input.ModelName != null && { ModelName: input.ModelName })), (input.ModelVersion != null && { ModelVersion: input.ModelVersion }));
201
193
  };
202
194
  var serializeAws_restJson1Models = function (input, context) {
203
195
  return input
@@ -247,6 +239,9 @@ var loadRestJsonErrorCode = function (output, data) {
247
239
  var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
248
240
  var sanitizeErrorCode = function (rawValue) {
249
241
  var cleanValue = rawValue;
242
+ if (typeof cleanValue === "number") {
243
+ cleanValue = cleanValue.toString();
244
+ }
250
245
  if (cleanValue.indexOf(":") >= 0) {
251
246
  cleanValue = cleanValue.split(":")[0];
252
247
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-sagemaker-edge",
3
3
  "description": "AWS SDK for JavaScript Sagemaker Edge Client for Node.js, Browser and React Native",
4
- "version": "3.121.0",
4
+ "version": "3.130.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -18,35 +18,35 @@
18
18
  "dependencies": {
19
19
  "@aws-crypto/sha256-browser": "2.0.0",
20
20
  "@aws-crypto/sha256-js": "2.0.0",
21
- "@aws-sdk/client-sts": "3.121.0",
22
- "@aws-sdk/config-resolver": "3.110.0",
23
- "@aws-sdk/credential-provider-node": "3.121.0",
24
- "@aws-sdk/fetch-http-handler": "3.110.0",
25
- "@aws-sdk/hash-node": "3.110.0",
26
- "@aws-sdk/invalid-dependency": "3.110.0",
27
- "@aws-sdk/middleware-content-length": "3.110.0",
28
- "@aws-sdk/middleware-host-header": "3.110.0",
29
- "@aws-sdk/middleware-logger": "3.110.0",
30
- "@aws-sdk/middleware-recursion-detection": "3.110.0",
31
- "@aws-sdk/middleware-retry": "3.118.1",
32
- "@aws-sdk/middleware-serde": "3.110.0",
33
- "@aws-sdk/middleware-signing": "3.110.0",
34
- "@aws-sdk/middleware-stack": "3.110.0",
35
- "@aws-sdk/middleware-user-agent": "3.110.0",
36
- "@aws-sdk/node-config-provider": "3.110.0",
37
- "@aws-sdk/node-http-handler": "3.118.1",
38
- "@aws-sdk/protocol-http": "3.110.0",
39
- "@aws-sdk/smithy-client": "3.110.0",
40
- "@aws-sdk/types": "3.110.0",
41
- "@aws-sdk/url-parser": "3.110.0",
21
+ "@aws-sdk/client-sts": "3.130.0",
22
+ "@aws-sdk/config-resolver": "3.130.0",
23
+ "@aws-sdk/credential-provider-node": "3.130.0",
24
+ "@aws-sdk/fetch-http-handler": "3.127.0",
25
+ "@aws-sdk/hash-node": "3.127.0",
26
+ "@aws-sdk/invalid-dependency": "3.127.0",
27
+ "@aws-sdk/middleware-content-length": "3.127.0",
28
+ "@aws-sdk/middleware-host-header": "3.127.0",
29
+ "@aws-sdk/middleware-logger": "3.127.0",
30
+ "@aws-sdk/middleware-recursion-detection": "3.127.0",
31
+ "@aws-sdk/middleware-retry": "3.127.0",
32
+ "@aws-sdk/middleware-serde": "3.127.0",
33
+ "@aws-sdk/middleware-signing": "3.130.0",
34
+ "@aws-sdk/middleware-stack": "3.127.0",
35
+ "@aws-sdk/middleware-user-agent": "3.127.0",
36
+ "@aws-sdk/node-config-provider": "3.127.0",
37
+ "@aws-sdk/node-http-handler": "3.127.0",
38
+ "@aws-sdk/protocol-http": "3.127.0",
39
+ "@aws-sdk/smithy-client": "3.127.0",
40
+ "@aws-sdk/types": "3.127.0",
41
+ "@aws-sdk/url-parser": "3.127.0",
42
42
  "@aws-sdk/util-base64-browser": "3.109.0",
43
43
  "@aws-sdk/util-base64-node": "3.55.0",
44
44
  "@aws-sdk/util-body-length-browser": "3.55.0",
45
45
  "@aws-sdk/util-body-length-node": "3.55.0",
46
- "@aws-sdk/util-defaults-mode-browser": "3.110.0",
47
- "@aws-sdk/util-defaults-mode-node": "3.110.0",
48
- "@aws-sdk/util-user-agent-browser": "3.110.0",
49
- "@aws-sdk/util-user-agent-node": "3.118.0",
46
+ "@aws-sdk/util-defaults-mode-browser": "3.127.0",
47
+ "@aws-sdk/util-defaults-mode-node": "3.130.0",
48
+ "@aws-sdk/util-user-agent-browser": "3.127.0",
49
+ "@aws-sdk/util-user-agent-node": "3.127.0",
50
50
  "@aws-sdk/util-utf8-browser": "3.109.0",
51
51
  "@aws-sdk/util-utf8-node": "3.109.0",
52
52
  "tslib": "^2.3.1"