@aws-sdk/client-sagemaker-edge 3.33.0 → 3.36.1
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 +47 -0
- package/{dist/cjs → dist-cjs}/SagemakerEdge.js +1 -5
- package/{dist/cjs → dist-cjs}/SagemakerEdgeClient.js +8 -17
- package/{dist/cjs → dist-cjs}/commands/GetDeviceRegistrationCommand.js +2 -27
- package/{dist/cjs → dist-cjs}/commands/SendHeartbeatCommand.js +2 -27
- package/{dist/cjs → dist-cjs}/endpoints.js +0 -1
- package/{dist/cjs → dist-cjs}/index.js +0 -1
- package/{dist/cjs → dist-cjs}/models/index.js +0 -1
- package/{dist/cjs → dist-cjs}/models/models_0.js +0 -19
- package/{dist/cjs → dist-cjs}/protocols/Aws_restJson1.js +2 -8
- package/{dist/cjs → dist-cjs}/runtimeConfig.browser.js +1 -5
- package/{dist/cjs → dist-cjs}/runtimeConfig.js +1 -5
- package/{dist/cjs → dist-cjs}/runtimeConfig.native.js +0 -4
- package/{dist/cjs → dist-cjs}/runtimeConfig.shared.js +1 -5
- package/{dist/es → dist-es}/SagemakerEdge.js +2 -6
- package/{dist/es → dist-es}/SagemakerEdgeClient.js +2 -11
- package/{dist/es → dist-es}/commands/GetDeviceRegistrationCommand.js +4 -30
- package/{dist/es → dist-es}/commands/SendHeartbeatCommand.js +4 -30
- package/{dist/es → dist-es}/endpoints.js +1 -2
- package/{dist/types/index.d.ts → dist-es/index.js} +0 -0
- package/{dist/types/models/index.d.ts → dist-es/models/index.js} +0 -0
- package/{dist/es → dist-es}/models/models_0.js +0 -19
- package/{dist/es → dist-es}/protocols/Aws_restJson1.js +25 -31
- package/{dist/es → dist-es}/runtimeConfig.browser.js +1 -5
- package/{dist/es → dist-es}/runtimeConfig.js +1 -5
- package/{dist/es → dist-es}/runtimeConfig.native.js +0 -4
- package/{dist/es → dist-es}/runtimeConfig.shared.js +1 -5
- package/{dist/types → dist-types}/SagemakerEdge.d.ts +2 -2
- package/{dist/types → dist-types}/SagemakerEdgeClient.d.ts +3 -3
- package/{dist/types → dist-types}/commands/GetDeviceRegistrationCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/SendHeartbeatCommand.d.ts +3 -3
- package/{dist/types → dist-types}/endpoints.d.ts +0 -0
- package/{index.ts → dist-types/index.d.ts} +0 -0
- package/{models/index.ts → dist-types/models/index.d.ts} +0 -0
- package/{dist/types → dist-types}/models/models_0.d.ts +0 -0
- package/{dist/types → dist-types}/protocols/Aws_restJson1.d.ts +2 -2
- package/{dist/types → dist-types}/runtimeConfig.browser.d.ts +0 -0
- package/{dist/types → dist-types}/runtimeConfig.d.ts +1 -1
- package/{dist/types → dist-types}/runtimeConfig.native.d.ts +0 -0
- package/{dist/types → dist-types}/runtimeConfig.shared.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/SagemakerEdge.d.ts +5 -11
- package/dist-types/ts3.4/SagemakerEdgeClient.d.ts +69 -0
- package/{dist/types → dist-types}/ts3.4/commands/GetDeviceRegistrationCommand.d.ts +5 -23
- package/dist-types/ts3.4/commands/SendHeartbeatCommand.d.ts +17 -0
- package/{dist/types → dist-types}/ts3.4/endpoints.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/index.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/models/index.d.ts +0 -0
- package/dist-types/ts3.4/models/models_0.d.ts +79 -0
- package/{dist/types → dist-types}/ts3.4/protocols/Aws_restJson1.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.browser.d.ts +1 -3
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.d.ts +2 -4
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.native.d.ts +1 -3
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.shared.d.ts +1 -3
- package/package.json +52 -49
- package/SagemakerEdge.ts +0 -81
- package/SagemakerEdgeClient.ts +0 -240
- package/commands/GetDeviceRegistrationCommand.ts +0 -94
- package/commands/SendHeartbeatCommand.ts +0 -94
- package/dist/cjs/SagemakerEdge.js.map +0 -1
- package/dist/cjs/SagemakerEdgeClient.js.map +0 -1
- package/dist/cjs/commands/GetDeviceRegistrationCommand.js.map +0 -1
- package/dist/cjs/commands/SendHeartbeatCommand.js.map +0 -1
- package/dist/cjs/endpoints.js.map +0 -1
- package/dist/cjs/index.js.map +0 -1
- package/dist/cjs/models/index.js.map +0 -1
- package/dist/cjs/models/models_0.js.map +0 -1
- package/dist/cjs/package.json +0 -91
- package/dist/cjs/protocols/Aws_restJson1.js.map +0 -1
- package/dist/cjs/runtimeConfig.browser.js.map +0 -1
- package/dist/cjs/runtimeConfig.js.map +0 -1
- package/dist/cjs/runtimeConfig.native.js.map +0 -1
- package/dist/cjs/runtimeConfig.shared.js.map +0 -1
- package/dist/es/SagemakerEdge.js.map +0 -1
- package/dist/es/SagemakerEdgeClient.js.map +0 -1
- package/dist/es/commands/GetDeviceRegistrationCommand.js.map +0 -1
- package/dist/es/commands/SendHeartbeatCommand.js.map +0 -1
- package/dist/es/endpoints.js.map +0 -1
- package/dist/es/index.js +0 -6
- package/dist/es/index.js.map +0 -1
- package/dist/es/models/index.js +0 -2
- package/dist/es/models/index.js.map +0 -1
- package/dist/es/models/models_0.js.map +0 -1
- package/dist/es/package.json +0 -91
- package/dist/es/protocols/Aws_restJson1.js.map +0 -1
- package/dist/es/runtimeConfig.browser.js.map +0 -1
- package/dist/es/runtimeConfig.js.map +0 -1
- package/dist/es/runtimeConfig.native.js.map +0 -1
- package/dist/es/runtimeConfig.shared.js.map +0 -1
- package/dist/types/ts3.4/SagemakerEdgeClient.d.ts +0 -134
- package/dist/types/ts3.4/commands/SendHeartbeatCommand.d.ts +0 -35
- package/dist/types/ts3.4/models/models_0.d.ts +0 -134
- package/endpoints.ts +0 -57
- package/jest.config.js +0 -4
- package/models/models_0.ts +0 -171
- package/protocols/Aws_restJson1.ts +0 -316
- package/runtimeConfig.browser.ts +0 -40
- package/runtimeConfig.native.ts +0 -16
- package/runtimeConfig.shared.ts +0 -16
- package/runtimeConfig.ts +0 -45
- package/tsconfig.es.json +0 -12
- package/tsconfig.json +0 -32
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
import { NodeHttpHandler } from "@aws-sdk/node-http-handler";
|
|
2
2
|
import { SagemakerEdgeClientConfig } from "./SagemakerEdgeClient";
|
|
3
|
-
|
|
4
|
-
* @internal
|
|
5
|
-
*/
|
|
3
|
+
|
|
6
4
|
export declare const getRuntimeConfig: (config: SagemakerEdgeClientConfig) => {
|
|
7
5
|
runtime: string;
|
|
8
6
|
base64Decoder: import("@aws-sdk/types").Decoder;
|
|
9
7
|
base64Encoder: import("@aws-sdk/types").Encoder;
|
|
10
8
|
bodyLengthChecker: (body: any) => number | undefined;
|
|
11
|
-
credentialDefaultProvider: import("@aws-sdk/client-sts/dist
|
|
9
|
+
credentialDefaultProvider: import("@aws-sdk/client-sts/dist-types/defaultStsRoleAssumers").DefaultCredentialProvider;
|
|
12
10
|
defaultUserAgentProvider: import("@aws-sdk/types").Provider<import("@aws-sdk/types").UserAgent>;
|
|
13
11
|
maxAttempts: number | import("@aws-sdk/types").Provider<number>;
|
|
14
12
|
region: string | import("@aws-sdk/types").Provider<string>;
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { Logger as __Logger } from "@aws-sdk/types";
|
|
2
2
|
import { SagemakerEdgeClientConfig } from "./SagemakerEdgeClient";
|
|
3
|
-
|
|
4
|
-
* @internal
|
|
5
|
-
*/
|
|
3
|
+
|
|
6
4
|
export declare const getRuntimeConfig: (config: SagemakerEdgeClientConfig) => {
|
|
7
5
|
apiVersion: string;
|
|
8
6
|
disableHostPrefix: boolean;
|
package/package.json
CHANGED
|
@@ -1,64 +1,58 @@
|
|
|
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.
|
|
4
|
+
"version": "3.36.1",
|
|
5
5
|
"scripts": {
|
|
6
|
-
"
|
|
7
|
-
"build-documentation": "yarn remove-documentation && typedoc ./",
|
|
8
|
-
"remove-definitions": "rimraf ./types",
|
|
9
|
-
"remove-dist": "rimraf ./dist",
|
|
10
|
-
"remove-documentation": "rimraf ./docs",
|
|
11
|
-
"test": "jest --coverage --passWithNoTests",
|
|
6
|
+
"build": "yarn build:cjs && yarn build:es && yarn build:types",
|
|
12
7
|
"build:cjs": "tsc -p tsconfig.json",
|
|
8
|
+
"build:docs": "yarn clean:docs && typedoc ./",
|
|
13
9
|
"build:es": "tsc -p tsconfig.es.json",
|
|
14
|
-
"build": "
|
|
15
|
-
"
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
"browser": {
|
|
21
|
-
"./runtimeConfig": "./runtimeConfig.browser"
|
|
22
|
-
},
|
|
23
|
-
"react-native": {
|
|
24
|
-
"./runtimeConfig": "./runtimeConfig.native"
|
|
10
|
+
"build:types": "tsc -p tsconfig.types.json",
|
|
11
|
+
"clean": "yarn clean:dist && yarn clean:docs",
|
|
12
|
+
"clean:dist": "rimraf ./dist",
|
|
13
|
+
"clean:docs": "rimraf ./docs",
|
|
14
|
+
"downlevel-dts": "downlevel-dts dist-types dist-types/ts3.4",
|
|
15
|
+
"test": "jest --coverage --passWithNoTests"
|
|
25
16
|
},
|
|
17
|
+
"main": "./dist-cjs/index.js",
|
|
18
|
+
"types": "./dist-types/index.d.ts",
|
|
19
|
+
"module": "./dist-es/index.js",
|
|
26
20
|
"sideEffects": false,
|
|
27
21
|
"dependencies": {
|
|
28
22
|
"@aws-crypto/sha256-browser": "^1.0.0",
|
|
29
23
|
"@aws-crypto/sha256-js": "^1.0.0",
|
|
30
|
-
"@aws-sdk/client-sts": "3.
|
|
31
|
-
"@aws-sdk/config-resolver": "3.
|
|
32
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
33
|
-
"@aws-sdk/fetch-http-handler": "3.
|
|
34
|
-
"@aws-sdk/hash-node": "3.
|
|
35
|
-
"@aws-sdk/invalid-dependency": "3.
|
|
36
|
-
"@aws-sdk/middleware-content-length": "3.
|
|
37
|
-
"@aws-sdk/middleware-host-header": "3.
|
|
38
|
-
"@aws-sdk/middleware-logger": "3.
|
|
39
|
-
"@aws-sdk/middleware-retry": "3.
|
|
40
|
-
"@aws-sdk/middleware-serde": "3.
|
|
41
|
-
"@aws-sdk/middleware-signing": "3.
|
|
42
|
-
"@aws-sdk/middleware-stack": "3.
|
|
43
|
-
"@aws-sdk/middleware-user-agent": "3.
|
|
44
|
-
"@aws-sdk/node-config-provider": "3.
|
|
45
|
-
"@aws-sdk/node-http-handler": "3.
|
|
46
|
-
"@aws-sdk/protocol-http": "3.
|
|
47
|
-
"@aws-sdk/smithy-client": "3.
|
|
48
|
-
"@aws-sdk/types": "3.
|
|
49
|
-
"@aws-sdk/url-parser": "3.
|
|
50
|
-
"@aws-sdk/util-base64-browser": "3.
|
|
51
|
-
"@aws-sdk/util-base64-node": "3.
|
|
52
|
-
"@aws-sdk/util-body-length-browser": "3.
|
|
53
|
-
"@aws-sdk/util-body-length-node": "3.
|
|
54
|
-
"@aws-sdk/util-user-agent-browser": "3.
|
|
55
|
-
"@aws-sdk/util-user-agent-node": "3.
|
|
56
|
-
"@aws-sdk/util-utf8-browser": "3.
|
|
57
|
-
"@aws-sdk/util-utf8-node": "3.
|
|
24
|
+
"@aws-sdk/client-sts": "3.36.1",
|
|
25
|
+
"@aws-sdk/config-resolver": "3.36.0",
|
|
26
|
+
"@aws-sdk/credential-provider-node": "3.36.1",
|
|
27
|
+
"@aws-sdk/fetch-http-handler": "3.36.0",
|
|
28
|
+
"@aws-sdk/hash-node": "3.36.0",
|
|
29
|
+
"@aws-sdk/invalid-dependency": "3.36.0",
|
|
30
|
+
"@aws-sdk/middleware-content-length": "3.36.0",
|
|
31
|
+
"@aws-sdk/middleware-host-header": "3.36.0",
|
|
32
|
+
"@aws-sdk/middleware-logger": "3.36.0",
|
|
33
|
+
"@aws-sdk/middleware-retry": "3.36.0",
|
|
34
|
+
"@aws-sdk/middleware-serde": "3.36.0",
|
|
35
|
+
"@aws-sdk/middleware-signing": "3.36.0",
|
|
36
|
+
"@aws-sdk/middleware-stack": "3.36.0",
|
|
37
|
+
"@aws-sdk/middleware-user-agent": "3.36.0",
|
|
38
|
+
"@aws-sdk/node-config-provider": "3.36.0",
|
|
39
|
+
"@aws-sdk/node-http-handler": "3.36.0",
|
|
40
|
+
"@aws-sdk/protocol-http": "3.36.0",
|
|
41
|
+
"@aws-sdk/smithy-client": "3.36.0",
|
|
42
|
+
"@aws-sdk/types": "3.36.0",
|
|
43
|
+
"@aws-sdk/url-parser": "3.36.0",
|
|
44
|
+
"@aws-sdk/util-base64-browser": "3.36.0",
|
|
45
|
+
"@aws-sdk/util-base64-node": "3.36.0",
|
|
46
|
+
"@aws-sdk/util-body-length-browser": "3.36.0",
|
|
47
|
+
"@aws-sdk/util-body-length-node": "3.36.0",
|
|
48
|
+
"@aws-sdk/util-user-agent-browser": "3.36.0",
|
|
49
|
+
"@aws-sdk/util-user-agent-node": "3.36.0",
|
|
50
|
+
"@aws-sdk/util-utf8-browser": "3.36.0",
|
|
51
|
+
"@aws-sdk/util-utf8-node": "3.36.0",
|
|
58
52
|
"tslib": "^2.3.0"
|
|
59
53
|
},
|
|
60
54
|
"devDependencies": {
|
|
61
|
-
"@aws-sdk/client-documentation-generator": "3.
|
|
55
|
+
"@aws-sdk/client-documentation-generator": "3.36.0",
|
|
62
56
|
"@types/node": "^12.7.5",
|
|
63
57
|
"downlevel-dts": "0.7.0",
|
|
64
58
|
"jest": "^26.1.0",
|
|
@@ -72,16 +66,25 @@
|
|
|
72
66
|
},
|
|
73
67
|
"typesVersions": {
|
|
74
68
|
"<4.0": {
|
|
75
|
-
"dist
|
|
76
|
-
"dist
|
|
69
|
+
"dist-types/*": [
|
|
70
|
+
"dist-types/ts3.4/*"
|
|
77
71
|
]
|
|
78
72
|
}
|
|
79
73
|
},
|
|
74
|
+
"files": [
|
|
75
|
+
"dist-*"
|
|
76
|
+
],
|
|
80
77
|
"author": {
|
|
81
78
|
"name": "AWS SDK for JavaScript Team",
|
|
82
79
|
"url": "https://aws.amazon.com/javascript/"
|
|
83
80
|
},
|
|
84
81
|
"license": "Apache-2.0",
|
|
82
|
+
"browser": {
|
|
83
|
+
"./dist-es/runtimeConfig": "./dist-es/runtimeConfig.browser"
|
|
84
|
+
},
|
|
85
|
+
"react-native": {
|
|
86
|
+
"./dist-es/runtimeConfig": "./dist-es/runtimeConfig.native"
|
|
87
|
+
},
|
|
85
88
|
"homepage": "https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-sagemaker-edge",
|
|
86
89
|
"repository": {
|
|
87
90
|
"type": "git",
|
package/SagemakerEdge.ts
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import { SagemakerEdgeClient } from "./SagemakerEdgeClient";
|
|
2
|
-
import {
|
|
3
|
-
GetDeviceRegistrationCommand,
|
|
4
|
-
GetDeviceRegistrationCommandInput,
|
|
5
|
-
GetDeviceRegistrationCommandOutput,
|
|
6
|
-
} from "./commands/GetDeviceRegistrationCommand";
|
|
7
|
-
import {
|
|
8
|
-
SendHeartbeatCommand,
|
|
9
|
-
SendHeartbeatCommandInput,
|
|
10
|
-
SendHeartbeatCommandOutput,
|
|
11
|
-
} from "./commands/SendHeartbeatCommand";
|
|
12
|
-
import { HttpHandlerOptions as __HttpHandlerOptions } from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* <p>SageMaker Edge Manager dataplane service for communicating with active agents.</p>
|
|
16
|
-
*/
|
|
17
|
-
export class SagemakerEdge extends SagemakerEdgeClient {
|
|
18
|
-
/**
|
|
19
|
-
* <p>Use to check if a device is registered with SageMaker Edge Manager.</p>
|
|
20
|
-
*/
|
|
21
|
-
public getDeviceRegistration(
|
|
22
|
-
args: GetDeviceRegistrationCommandInput,
|
|
23
|
-
options?: __HttpHandlerOptions
|
|
24
|
-
): Promise<GetDeviceRegistrationCommandOutput>;
|
|
25
|
-
public getDeviceRegistration(
|
|
26
|
-
args: GetDeviceRegistrationCommandInput,
|
|
27
|
-
cb: (err: any, data?: GetDeviceRegistrationCommandOutput) => void
|
|
28
|
-
): void;
|
|
29
|
-
public getDeviceRegistration(
|
|
30
|
-
args: GetDeviceRegistrationCommandInput,
|
|
31
|
-
options: __HttpHandlerOptions,
|
|
32
|
-
cb: (err: any, data?: GetDeviceRegistrationCommandOutput) => void
|
|
33
|
-
): void;
|
|
34
|
-
public getDeviceRegistration(
|
|
35
|
-
args: GetDeviceRegistrationCommandInput,
|
|
36
|
-
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: GetDeviceRegistrationCommandOutput) => void),
|
|
37
|
-
cb?: (err: any, data?: GetDeviceRegistrationCommandOutput) => void
|
|
38
|
-
): Promise<GetDeviceRegistrationCommandOutput> | void {
|
|
39
|
-
const command = new GetDeviceRegistrationCommand(args);
|
|
40
|
-
if (typeof optionsOrCb === "function") {
|
|
41
|
-
this.send(command, optionsOrCb);
|
|
42
|
-
} else if (typeof cb === "function") {
|
|
43
|
-
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
|
|
44
|
-
this.send(command, optionsOrCb || {}, cb);
|
|
45
|
-
} else {
|
|
46
|
-
return this.send(command, optionsOrCb);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
/**
|
|
51
|
-
* <p>Use to get the current status of devices registered on SageMaker Edge Manager.</p>
|
|
52
|
-
*/
|
|
53
|
-
public sendHeartbeat(
|
|
54
|
-
args: SendHeartbeatCommandInput,
|
|
55
|
-
options?: __HttpHandlerOptions
|
|
56
|
-
): Promise<SendHeartbeatCommandOutput>;
|
|
57
|
-
public sendHeartbeat(
|
|
58
|
-
args: SendHeartbeatCommandInput,
|
|
59
|
-
cb: (err: any, data?: SendHeartbeatCommandOutput) => void
|
|
60
|
-
): void;
|
|
61
|
-
public sendHeartbeat(
|
|
62
|
-
args: SendHeartbeatCommandInput,
|
|
63
|
-
options: __HttpHandlerOptions,
|
|
64
|
-
cb: (err: any, data?: SendHeartbeatCommandOutput) => void
|
|
65
|
-
): void;
|
|
66
|
-
public sendHeartbeat(
|
|
67
|
-
args: SendHeartbeatCommandInput,
|
|
68
|
-
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: SendHeartbeatCommandOutput) => void),
|
|
69
|
-
cb?: (err: any, data?: SendHeartbeatCommandOutput) => void
|
|
70
|
-
): Promise<SendHeartbeatCommandOutput> | void {
|
|
71
|
-
const command = new SendHeartbeatCommand(args);
|
|
72
|
-
if (typeof optionsOrCb === "function") {
|
|
73
|
-
this.send(command, optionsOrCb);
|
|
74
|
-
} else if (typeof cb === "function") {
|
|
75
|
-
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
|
|
76
|
-
this.send(command, optionsOrCb || {}, cb);
|
|
77
|
-
} else {
|
|
78
|
-
return this.send(command, optionsOrCb);
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
}
|
package/SagemakerEdgeClient.ts
DELETED
|
@@ -1,240 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
GetDeviceRegistrationCommandInput,
|
|
3
|
-
GetDeviceRegistrationCommandOutput,
|
|
4
|
-
} from "./commands/GetDeviceRegistrationCommand";
|
|
5
|
-
import { SendHeartbeatCommandInput, SendHeartbeatCommandOutput } from "./commands/SendHeartbeatCommand";
|
|
6
|
-
import { getRuntimeConfig as __getRuntimeConfig } from "./runtimeConfig";
|
|
7
|
-
import {
|
|
8
|
-
EndpointsInputConfig,
|
|
9
|
-
EndpointsResolvedConfig,
|
|
10
|
-
RegionInputConfig,
|
|
11
|
-
RegionResolvedConfig,
|
|
12
|
-
resolveEndpointsConfig,
|
|
13
|
-
resolveRegionConfig,
|
|
14
|
-
} from "@aws-sdk/config-resolver";
|
|
15
|
-
import { getContentLengthPlugin } from "@aws-sdk/middleware-content-length";
|
|
16
|
-
import {
|
|
17
|
-
HostHeaderInputConfig,
|
|
18
|
-
HostHeaderResolvedConfig,
|
|
19
|
-
getHostHeaderPlugin,
|
|
20
|
-
resolveHostHeaderConfig,
|
|
21
|
-
} from "@aws-sdk/middleware-host-header";
|
|
22
|
-
import { getLoggerPlugin } from "@aws-sdk/middleware-logger";
|
|
23
|
-
import { RetryInputConfig, RetryResolvedConfig, getRetryPlugin, resolveRetryConfig } from "@aws-sdk/middleware-retry";
|
|
24
|
-
import {
|
|
25
|
-
AwsAuthInputConfig,
|
|
26
|
-
AwsAuthResolvedConfig,
|
|
27
|
-
getAwsAuthPlugin,
|
|
28
|
-
resolveAwsAuthConfig,
|
|
29
|
-
} from "@aws-sdk/middleware-signing";
|
|
30
|
-
import {
|
|
31
|
-
UserAgentInputConfig,
|
|
32
|
-
UserAgentResolvedConfig,
|
|
33
|
-
getUserAgentPlugin,
|
|
34
|
-
resolveUserAgentConfig,
|
|
35
|
-
} from "@aws-sdk/middleware-user-agent";
|
|
36
|
-
import { HttpHandler as __HttpHandler } from "@aws-sdk/protocol-http";
|
|
37
|
-
import {
|
|
38
|
-
Client as __Client,
|
|
39
|
-
SmithyConfiguration as __SmithyConfiguration,
|
|
40
|
-
SmithyResolvedConfiguration as __SmithyResolvedConfiguration,
|
|
41
|
-
} from "@aws-sdk/smithy-client";
|
|
42
|
-
import {
|
|
43
|
-
Provider,
|
|
44
|
-
RegionInfoProvider,
|
|
45
|
-
Credentials as __Credentials,
|
|
46
|
-
Decoder as __Decoder,
|
|
47
|
-
Encoder as __Encoder,
|
|
48
|
-
Hash as __Hash,
|
|
49
|
-
HashConstructor as __HashConstructor,
|
|
50
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
51
|
-
Logger as __Logger,
|
|
52
|
-
Provider as __Provider,
|
|
53
|
-
StreamCollector as __StreamCollector,
|
|
54
|
-
UrlParser as __UrlParser,
|
|
55
|
-
UserAgent as __UserAgent,
|
|
56
|
-
} from "@aws-sdk/types";
|
|
57
|
-
|
|
58
|
-
export type ServiceInputTypes = GetDeviceRegistrationCommandInput | SendHeartbeatCommandInput;
|
|
59
|
-
|
|
60
|
-
export type ServiceOutputTypes = GetDeviceRegistrationCommandOutput | SendHeartbeatCommandOutput;
|
|
61
|
-
|
|
62
|
-
export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__HttpHandlerOptions>> {
|
|
63
|
-
/**
|
|
64
|
-
* The HTTP handler to use. Fetch in browser and Https in Nodejs.
|
|
65
|
-
*/
|
|
66
|
-
requestHandler?: __HttpHandler;
|
|
67
|
-
|
|
68
|
-
/**
|
|
69
|
-
* A constructor for a class implementing the {@link __Hash} interface
|
|
70
|
-
* that computes the SHA-256 HMAC or checksum of a string or binary buffer.
|
|
71
|
-
* @internal
|
|
72
|
-
*/
|
|
73
|
-
sha256?: __HashConstructor;
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* The function that will be used to convert strings into HTTP endpoints.
|
|
77
|
-
* @internal
|
|
78
|
-
*/
|
|
79
|
-
urlParser?: __UrlParser;
|
|
80
|
-
|
|
81
|
-
/**
|
|
82
|
-
* A function that can calculate the length of a request body.
|
|
83
|
-
* @internal
|
|
84
|
-
*/
|
|
85
|
-
bodyLengthChecker?: (body: any) => number | undefined;
|
|
86
|
-
|
|
87
|
-
/**
|
|
88
|
-
* A function that converts a stream into an array of bytes.
|
|
89
|
-
* @internal
|
|
90
|
-
*/
|
|
91
|
-
streamCollector?: __StreamCollector;
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* The function that will be used to convert a base64-encoded string to a byte array.
|
|
95
|
-
* @internal
|
|
96
|
-
*/
|
|
97
|
-
base64Decoder?: __Decoder;
|
|
98
|
-
|
|
99
|
-
/**
|
|
100
|
-
* The function that will be used to convert binary data to a base64-encoded string.
|
|
101
|
-
* @internal
|
|
102
|
-
*/
|
|
103
|
-
base64Encoder?: __Encoder;
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
* The function that will be used to convert a UTF8-encoded string to a byte array.
|
|
107
|
-
* @internal
|
|
108
|
-
*/
|
|
109
|
-
utf8Decoder?: __Decoder;
|
|
110
|
-
|
|
111
|
-
/**
|
|
112
|
-
* The function that will be used to convert binary data to a UTF-8 encoded string.
|
|
113
|
-
* @internal
|
|
114
|
-
*/
|
|
115
|
-
utf8Encoder?: __Encoder;
|
|
116
|
-
|
|
117
|
-
/**
|
|
118
|
-
* The runtime environment.
|
|
119
|
-
* @internal
|
|
120
|
-
*/
|
|
121
|
-
runtime?: string;
|
|
122
|
-
|
|
123
|
-
/**
|
|
124
|
-
* Disable dyanamically changing the endpoint of the client based on the hostPrefix
|
|
125
|
-
* trait of an operation.
|
|
126
|
-
*/
|
|
127
|
-
disableHostPrefix?: boolean;
|
|
128
|
-
|
|
129
|
-
/**
|
|
130
|
-
* Value for how many times a request will be made at most in case of retry.
|
|
131
|
-
*/
|
|
132
|
-
maxAttempts?: number | __Provider<number>;
|
|
133
|
-
|
|
134
|
-
/**
|
|
135
|
-
* Specifies which retry algorithm to use.
|
|
136
|
-
*/
|
|
137
|
-
retryMode?: string | __Provider<string>;
|
|
138
|
-
|
|
139
|
-
/**
|
|
140
|
-
* Optional logger for logging debug/info/warn/error.
|
|
141
|
-
*/
|
|
142
|
-
logger?: __Logger;
|
|
143
|
-
|
|
144
|
-
/**
|
|
145
|
-
* Unique service identifier.
|
|
146
|
-
* @internal
|
|
147
|
-
*/
|
|
148
|
-
serviceId?: string;
|
|
149
|
-
|
|
150
|
-
/**
|
|
151
|
-
* The AWS region to which this client will send requests
|
|
152
|
-
*/
|
|
153
|
-
region?: string | __Provider<string>;
|
|
154
|
-
|
|
155
|
-
/**
|
|
156
|
-
* Default credentials provider; Not available in browser runtime.
|
|
157
|
-
* @internal
|
|
158
|
-
*/
|
|
159
|
-
credentialDefaultProvider?: (input: any) => __Provider<__Credentials>;
|
|
160
|
-
|
|
161
|
-
/**
|
|
162
|
-
* Fetch related hostname, signing name or signing region with given region.
|
|
163
|
-
* @internal
|
|
164
|
-
*/
|
|
165
|
-
regionInfoProvider?: RegionInfoProvider;
|
|
166
|
-
|
|
167
|
-
/**
|
|
168
|
-
* The provider populating default tracking information to be sent with `user-agent`, `x-amz-user-agent` header
|
|
169
|
-
* @internal
|
|
170
|
-
*/
|
|
171
|
-
defaultUserAgentProvider?: Provider<__UserAgent>;
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
type SagemakerEdgeClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> &
|
|
175
|
-
ClientDefaults &
|
|
176
|
-
RegionInputConfig &
|
|
177
|
-
EndpointsInputConfig &
|
|
178
|
-
RetryInputConfig &
|
|
179
|
-
HostHeaderInputConfig &
|
|
180
|
-
AwsAuthInputConfig &
|
|
181
|
-
UserAgentInputConfig;
|
|
182
|
-
/**
|
|
183
|
-
* The configuration interface of SagemakerEdgeClient class constructor that set the region, credentials and other options.
|
|
184
|
-
*/
|
|
185
|
-
export interface SagemakerEdgeClientConfig extends SagemakerEdgeClientConfigType {}
|
|
186
|
-
|
|
187
|
-
type SagemakerEdgeClientResolvedConfigType = __SmithyResolvedConfiguration<__HttpHandlerOptions> &
|
|
188
|
-
Required<ClientDefaults> &
|
|
189
|
-
RegionResolvedConfig &
|
|
190
|
-
EndpointsResolvedConfig &
|
|
191
|
-
RetryResolvedConfig &
|
|
192
|
-
HostHeaderResolvedConfig &
|
|
193
|
-
AwsAuthResolvedConfig &
|
|
194
|
-
UserAgentResolvedConfig;
|
|
195
|
-
/**
|
|
196
|
-
* The resolved configuration interface of SagemakerEdgeClient class. This is resolved and normalized from the {@link SagemakerEdgeClientConfig | constructor configuration interface}.
|
|
197
|
-
*/
|
|
198
|
-
export interface SagemakerEdgeClientResolvedConfig extends SagemakerEdgeClientResolvedConfigType {}
|
|
199
|
-
|
|
200
|
-
/**
|
|
201
|
-
* <p>SageMaker Edge Manager dataplane service for communicating with active agents.</p>
|
|
202
|
-
*/
|
|
203
|
-
export class SagemakerEdgeClient extends __Client<
|
|
204
|
-
__HttpHandlerOptions,
|
|
205
|
-
ServiceInputTypes,
|
|
206
|
-
ServiceOutputTypes,
|
|
207
|
-
SagemakerEdgeClientResolvedConfig
|
|
208
|
-
> {
|
|
209
|
-
/**
|
|
210
|
-
* The resolved configuration of SagemakerEdgeClient class. This is resolved and normalized from the {@link SagemakerEdgeClientConfig | constructor configuration interface}.
|
|
211
|
-
*/
|
|
212
|
-
readonly config: SagemakerEdgeClientResolvedConfig;
|
|
213
|
-
|
|
214
|
-
constructor(configuration: SagemakerEdgeClientConfig) {
|
|
215
|
-
let _config_0 = __getRuntimeConfig(configuration);
|
|
216
|
-
let _config_1 = resolveRegionConfig(_config_0);
|
|
217
|
-
let _config_2 = resolveEndpointsConfig(_config_1);
|
|
218
|
-
let _config_3 = resolveRetryConfig(_config_2);
|
|
219
|
-
let _config_4 = resolveHostHeaderConfig(_config_3);
|
|
220
|
-
let _config_5 = resolveAwsAuthConfig(_config_4);
|
|
221
|
-
let _config_6 = resolveUserAgentConfig(_config_5);
|
|
222
|
-
super(_config_6);
|
|
223
|
-
this.config = _config_6;
|
|
224
|
-
this.middlewareStack.use(getRetryPlugin(this.config));
|
|
225
|
-
this.middlewareStack.use(getContentLengthPlugin(this.config));
|
|
226
|
-
this.middlewareStack.use(getHostHeaderPlugin(this.config));
|
|
227
|
-
this.middlewareStack.use(getLoggerPlugin(this.config));
|
|
228
|
-
this.middlewareStack.use(getAwsAuthPlugin(this.config));
|
|
229
|
-
this.middlewareStack.use(getUserAgentPlugin(this.config));
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
/**
|
|
233
|
-
* Destroy underlying resources, like sockets. It's usually not necessary to do this.
|
|
234
|
-
* However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.
|
|
235
|
-
* Otherwise, sockets might stay open for quite a long time before the server terminates them.
|
|
236
|
-
*/
|
|
237
|
-
destroy(): void {
|
|
238
|
-
super.destroy();
|
|
239
|
-
}
|
|
240
|
-
}
|
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
import { SagemakerEdgeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SagemakerEdgeClient";
|
|
2
|
-
import { GetDeviceRegistrationRequest, GetDeviceRegistrationResult } from "../models/models_0";
|
|
3
|
-
import {
|
|
4
|
-
deserializeAws_restJson1GetDeviceRegistrationCommand,
|
|
5
|
-
serializeAws_restJson1GetDeviceRegistrationCommand,
|
|
6
|
-
} from "../protocols/Aws_restJson1";
|
|
7
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
8
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
9
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
10
|
-
import {
|
|
11
|
-
FinalizeHandlerArguments,
|
|
12
|
-
Handler,
|
|
13
|
-
HandlerExecutionContext,
|
|
14
|
-
MiddlewareStack,
|
|
15
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
16
|
-
MetadataBearer as __MetadataBearer,
|
|
17
|
-
SerdeContext as __SerdeContext,
|
|
18
|
-
} from "@aws-sdk/types";
|
|
19
|
-
|
|
20
|
-
export interface GetDeviceRegistrationCommandInput extends GetDeviceRegistrationRequest {}
|
|
21
|
-
export interface GetDeviceRegistrationCommandOutput extends GetDeviceRegistrationResult, __MetadataBearer {}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* <p>Use to check if a device is registered with SageMaker Edge Manager.</p>
|
|
25
|
-
* @example
|
|
26
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
27
|
-
* ```javascript
|
|
28
|
-
* import { SagemakerEdgeClient, GetDeviceRegistrationCommand } from "@aws-sdk/client-sagemaker-edge"; // ES Modules import
|
|
29
|
-
* // const { SagemakerEdgeClient, GetDeviceRegistrationCommand } = require("@aws-sdk/client-sagemaker-edge"); // CommonJS import
|
|
30
|
-
* const client = new SagemakerEdgeClient(config);
|
|
31
|
-
* const command = new GetDeviceRegistrationCommand(input);
|
|
32
|
-
* const response = await client.send(command);
|
|
33
|
-
* ```
|
|
34
|
-
*
|
|
35
|
-
* @see {@link GetDeviceRegistrationCommandInput} for command's `input` shape.
|
|
36
|
-
* @see {@link GetDeviceRegistrationCommandOutput} for command's `response` shape.
|
|
37
|
-
* @see {@link SagemakerEdgeClientResolvedConfig | config} for command's `input` shape.
|
|
38
|
-
*
|
|
39
|
-
*/
|
|
40
|
-
export class GetDeviceRegistrationCommand extends $Command<
|
|
41
|
-
GetDeviceRegistrationCommandInput,
|
|
42
|
-
GetDeviceRegistrationCommandOutput,
|
|
43
|
-
SagemakerEdgeClientResolvedConfig
|
|
44
|
-
> {
|
|
45
|
-
// Start section: command_properties
|
|
46
|
-
// End section: command_properties
|
|
47
|
-
|
|
48
|
-
constructor(readonly input: GetDeviceRegistrationCommandInput) {
|
|
49
|
-
// Start section: command_constructor
|
|
50
|
-
super();
|
|
51
|
-
// End section: command_constructor
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* @internal
|
|
56
|
-
*/
|
|
57
|
-
resolveMiddleware(
|
|
58
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
59
|
-
configuration: SagemakerEdgeClientResolvedConfig,
|
|
60
|
-
options?: __HttpHandlerOptions
|
|
61
|
-
): Handler<GetDeviceRegistrationCommandInput, GetDeviceRegistrationCommandOutput> {
|
|
62
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
63
|
-
|
|
64
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
65
|
-
|
|
66
|
-
const { logger } = configuration;
|
|
67
|
-
const clientName = "SagemakerEdgeClient";
|
|
68
|
-
const commandName = "GetDeviceRegistrationCommand";
|
|
69
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
70
|
-
logger,
|
|
71
|
-
clientName,
|
|
72
|
-
commandName,
|
|
73
|
-
inputFilterSensitiveLog: GetDeviceRegistrationRequest.filterSensitiveLog,
|
|
74
|
-
outputFilterSensitiveLog: GetDeviceRegistrationResult.filterSensitiveLog,
|
|
75
|
-
};
|
|
76
|
-
const { requestHandler } = configuration;
|
|
77
|
-
return stack.resolve(
|
|
78
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
79
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
80
|
-
handlerExecutionContext
|
|
81
|
-
);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
private serialize(input: GetDeviceRegistrationCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
85
|
-
return serializeAws_restJson1GetDeviceRegistrationCommand(input, context);
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<GetDeviceRegistrationCommandOutput> {
|
|
89
|
-
return deserializeAws_restJson1GetDeviceRegistrationCommand(output, context);
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
// Start section: command_body_extra
|
|
93
|
-
// End section: command_body_extra
|
|
94
|
-
}
|