@aws-sdk/client-arc-zonal-shift 3.461.0 → 3.464.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.
Files changed (55) hide show
  1. package/README.md +74 -22
  2. package/dist-cjs/ARCZonalShift.js +10 -0
  3. package/dist-cjs/commands/CreatePracticeRunConfigurationCommand.js +51 -0
  4. package/dist-cjs/commands/DeletePracticeRunConfigurationCommand.js +51 -0
  5. package/dist-cjs/commands/ListAutoshiftsCommand.js +51 -0
  6. package/dist-cjs/commands/UpdatePracticeRunConfigurationCommand.js +51 -0
  7. package/dist-cjs/commands/UpdateZonalAutoshiftConfigurationCommand.js +51 -0
  8. package/dist-cjs/commands/index.js +5 -0
  9. package/dist-cjs/models/models_0.js +61 -34
  10. package/dist-cjs/pagination/ListAutoshiftsPaginator.js +29 -0
  11. package/dist-cjs/pagination/index.js +1 -0
  12. package/dist-cjs/protocols/Aws_restJson1.js +419 -2
  13. package/dist-es/ARCZonalShift.js +10 -0
  14. package/dist-es/commands/CreatePracticeRunConfigurationCommand.js +47 -0
  15. package/dist-es/commands/DeletePracticeRunConfigurationCommand.js +47 -0
  16. package/dist-es/commands/ListAutoshiftsCommand.js +47 -0
  17. package/dist-es/commands/UpdatePracticeRunConfigurationCommand.js +47 -0
  18. package/dist-es/commands/UpdateZonalAutoshiftConfigurationCommand.js +47 -0
  19. package/dist-es/commands/index.js +5 -0
  20. package/dist-es/models/models_0.js +58 -31
  21. package/dist-es/pagination/ListAutoshiftsPaginator.js +25 -0
  22. package/dist-es/pagination/index.js +1 -0
  23. package/dist-es/protocols/Aws_restJson1.js +408 -1
  24. package/dist-types/ARCZonalShift.d.ts +62 -15
  25. package/dist-types/ARCZonalShiftClient.d.ts +34 -17
  26. package/dist-types/commands/CancelZonalShiftCommand.d.ts +5 -2
  27. package/dist-types/commands/CreatePracticeRunConfigurationCommand.d.ts +138 -0
  28. package/dist-types/commands/DeletePracticeRunConfigurationCommand.d.ts +95 -0
  29. package/dist-types/commands/GetManagedResourceCommand.d.ts +33 -4
  30. package/dist-types/commands/ListAutoshiftsCommand.d.ts +95 -0
  31. package/dist-types/commands/ListManagedResourcesCommand.d.ts +28 -3
  32. package/dist-types/commands/ListZonalShiftsCommand.d.ts +8 -2
  33. package/dist-types/commands/StartZonalShiftCommand.d.ts +8 -7
  34. package/dist-types/commands/UpdatePracticeRunConfigurationCommand.d.ts +133 -0
  35. package/dist-types/commands/UpdateZonalAutoshiftConfigurationCommand.d.ts +96 -0
  36. package/dist-types/commands/UpdateZonalShiftCommand.d.ts +2 -2
  37. package/dist-types/commands/index.d.ts +5 -0
  38. package/dist-types/index.d.ts +27 -15
  39. package/dist-types/models/models_0.d.ts +698 -95
  40. package/dist-types/pagination/ListAutoshiftsPaginator.d.ts +7 -0
  41. package/dist-types/pagination/index.d.ts +1 -0
  42. package/dist-types/protocols/Aws_restJson1.d.ts +45 -0
  43. package/dist-types/ts3.4/ARCZonalShift.d.ts +91 -0
  44. package/dist-types/ts3.4/ARCZonalShiftClient.d.ts +30 -0
  45. package/dist-types/ts3.4/commands/CreatePracticeRunConfigurationCommand.d.ts +42 -0
  46. package/dist-types/ts3.4/commands/DeletePracticeRunConfigurationCommand.d.ts +42 -0
  47. package/dist-types/ts3.4/commands/ListAutoshiftsCommand.d.ts +38 -0
  48. package/dist-types/ts3.4/commands/UpdatePracticeRunConfigurationCommand.d.ts +42 -0
  49. package/dist-types/ts3.4/commands/UpdateZonalAutoshiftConfigurationCommand.d.ts +42 -0
  50. package/dist-types/ts3.4/commands/index.d.ts +5 -0
  51. package/dist-types/ts3.4/models/models_0.d.ts +143 -23
  52. package/dist-types/ts3.4/pagination/ListAutoshiftsPaginator.d.ts +11 -0
  53. package/dist-types/ts3.4/pagination/index.d.ts +1 -0
  54. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +60 -0
  55. package/package.json +2 -2
@@ -0,0 +1,47 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
5
+ import { de_UpdatePracticeRunConfigurationCommand, se_UpdatePracticeRunConfigurationCommand, } from "../protocols/Aws_restJson1";
6
+ export { $Command };
7
+ export class UpdatePracticeRunConfigurationCommand extends $Command {
8
+ static getEndpointParameterInstructions() {
9
+ return {
10
+ UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
11
+ Endpoint: { type: "builtInParams", name: "endpoint" },
12
+ Region: { type: "builtInParams", name: "region" },
13
+ UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
14
+ };
15
+ }
16
+ constructor(input) {
17
+ super();
18
+ this.input = input;
19
+ }
20
+ resolveMiddleware(clientStack, configuration, options) {
21
+ this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
22
+ this.middlewareStack.use(getEndpointPlugin(configuration, UpdatePracticeRunConfigurationCommand.getEndpointParameterInstructions()));
23
+ const stack = clientStack.concat(this.middlewareStack);
24
+ const { logger } = configuration;
25
+ const clientName = "ARCZonalShiftClient";
26
+ const commandName = "UpdatePracticeRunConfigurationCommand";
27
+ const handlerExecutionContext = {
28
+ logger,
29
+ clientName,
30
+ commandName,
31
+ inputFilterSensitiveLog: (_) => _,
32
+ outputFilterSensitiveLog: (_) => _,
33
+ [SMITHY_CONTEXT_KEY]: {
34
+ service: "PercDataPlane",
35
+ operation: "UpdatePracticeRunConfiguration",
36
+ },
37
+ };
38
+ const { requestHandler } = configuration;
39
+ return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
40
+ }
41
+ serialize(input, context) {
42
+ return se_UpdatePracticeRunConfigurationCommand(input, context);
43
+ }
44
+ deserialize(output, context) {
45
+ return de_UpdatePracticeRunConfigurationCommand(output, context);
46
+ }
47
+ }
@@ -0,0 +1,47 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
5
+ import { de_UpdateZonalAutoshiftConfigurationCommand, se_UpdateZonalAutoshiftConfigurationCommand, } from "../protocols/Aws_restJson1";
6
+ export { $Command };
7
+ export class UpdateZonalAutoshiftConfigurationCommand extends $Command {
8
+ static getEndpointParameterInstructions() {
9
+ return {
10
+ UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
11
+ Endpoint: { type: "builtInParams", name: "endpoint" },
12
+ Region: { type: "builtInParams", name: "region" },
13
+ UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
14
+ };
15
+ }
16
+ constructor(input) {
17
+ super();
18
+ this.input = input;
19
+ }
20
+ resolveMiddleware(clientStack, configuration, options) {
21
+ this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
22
+ this.middlewareStack.use(getEndpointPlugin(configuration, UpdateZonalAutoshiftConfigurationCommand.getEndpointParameterInstructions()));
23
+ const stack = clientStack.concat(this.middlewareStack);
24
+ const { logger } = configuration;
25
+ const clientName = "ARCZonalShiftClient";
26
+ const commandName = "UpdateZonalAutoshiftConfigurationCommand";
27
+ const handlerExecutionContext = {
28
+ logger,
29
+ clientName,
30
+ commandName,
31
+ inputFilterSensitiveLog: (_) => _,
32
+ outputFilterSensitiveLog: (_) => _,
33
+ [SMITHY_CONTEXT_KEY]: {
34
+ service: "PercDataPlane",
35
+ operation: "UpdateZonalAutoshiftConfiguration",
36
+ },
37
+ };
38
+ const { requestHandler } = configuration;
39
+ return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
40
+ }
41
+ serialize(input, context) {
42
+ return se_UpdateZonalAutoshiftConfigurationCommand(input, context);
43
+ }
44
+ deserialize(output, context) {
45
+ return de_UpdateZonalAutoshiftConfigurationCommand(output, context);
46
+ }
47
+ }
@@ -1,6 +1,11 @@
1
1
  export * from "./CancelZonalShiftCommand";
2
+ export * from "./CreatePracticeRunConfigurationCommand";
3
+ export * from "./DeletePracticeRunConfigurationCommand";
2
4
  export * from "./GetManagedResourceCommand";
5
+ export * from "./ListAutoshiftsCommand";
3
6
  export * from "./ListManagedResourcesCommand";
4
7
  export * from "./ListZonalShiftsCommand";
5
8
  export * from "./StartZonalShiftCommand";
9
+ export * from "./UpdatePracticeRunConfigurationCommand";
10
+ export * from "./UpdateZonalAutoshiftConfigurationCommand";
6
11
  export * from "./UpdateZonalShiftCommand";
@@ -15,25 +15,6 @@ export const AppliedStatus = {
15
15
  APPLIED: "APPLIED",
16
16
  NOT_APPLIED: "NOT_APPLIED",
17
17
  };
18
- export const ConflictExceptionReason = {
19
- SIMULTANEOUS_ZONAL_SHIFTS_CONFLICT: "SimultaneousZonalShiftsConflict",
20
- ZONAL_SHIFT_ALREADY_EXISTS: "ZonalShiftAlreadyExists",
21
- ZONAL_SHIFT_STATUS_NOT_ACTIVE: "ZonalShiftStatusNotActive",
22
- };
23
- export class ConflictException extends __BaseException {
24
- constructor(opts) {
25
- super({
26
- name: "ConflictException",
27
- $fault: "client",
28
- ...opts,
29
- });
30
- this.name = "ConflictException";
31
- this.$fault = "client";
32
- Object.setPrototypeOf(this, ConflictException.prototype);
33
- this.reason = opts.reason;
34
- this.zonalShiftId = opts.zonalShiftId;
35
- }
36
- }
37
18
  export class InternalServerException extends __BaseException {
38
19
  constructor(opts) {
39
20
  super({
@@ -46,18 +27,10 @@ export class InternalServerException extends __BaseException {
46
27
  Object.setPrototypeOf(this, InternalServerException.prototype);
47
28
  }
48
29
  }
49
- export class ResourceNotFoundException extends __BaseException {
50
- constructor(opts) {
51
- super({
52
- name: "ResourceNotFoundException",
53
- $fault: "client",
54
- ...opts,
55
- });
56
- this.name = "ResourceNotFoundException";
57
- this.$fault = "client";
58
- Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
59
- }
60
- }
30
+ export const AutoshiftExecutionStatus = {
31
+ ACTIVE: "ACTIVE",
32
+ COMPLETED: "COMPLETED",
33
+ };
61
34
  export class ThrottlingException extends __BaseException {
62
35
  constructor(opts) {
63
36
  super({
@@ -71,8 +44,11 @@ export class ThrottlingException extends __BaseException {
71
44
  }
72
45
  }
73
46
  export const ValidationExceptionReason = {
47
+ INVALID_ALARM_CONDITION: "InvalidAlarmCondition",
74
48
  INVALID_AZ: "InvalidAz",
49
+ INVALID_CONDITION_TYPE: "InvalidConditionType",
75
50
  INVALID_EXPIRES_IN: "InvalidExpiresIn",
51
+ INVALID_PRACTICE_BLOCKER: "InvalidPracticeBlocker",
76
52
  INVALID_RESOURCE_IDENTIFIER: "InvalidResourceIdentifier",
77
53
  INVALID_STATUS: "InvalidStatus",
78
54
  INVALID_TOKEN: "InvalidToken",
@@ -92,8 +68,59 @@ export class ValidationException extends __BaseException {
92
68
  this.reason = opts.reason;
93
69
  }
94
70
  }
71
+ export const AutoshiftAppliedStatus = {
72
+ APPLIED: "APPLIED",
73
+ NOT_APPLIED: "NOT_APPLIED",
74
+ };
75
+ export const ConflictExceptionReason = {
76
+ AUTOSHIFT_ENABLED: "AutoShiftEnabled",
77
+ PRACTICE_CONFIGURATION_ALREADY_EXISTS: "PracticeConfigurationAlreadyExists",
78
+ PRACTICE_CONFIGURATION_DOES_NOT_EXIST: "PracticeConfigurationDoesNotExist",
79
+ SIMULTANEOUS_ZONAL_SHIFTS_CONFLICT: "SimultaneousZonalShiftsConflict",
80
+ ZONAL_SHIFT_ALREADY_EXISTS: "ZonalShiftAlreadyExists",
81
+ ZONAL_SHIFT_STATUS_NOT_ACTIVE: "ZonalShiftStatusNotActive",
82
+ };
83
+ export class ConflictException extends __BaseException {
84
+ constructor(opts) {
85
+ super({
86
+ name: "ConflictException",
87
+ $fault: "client",
88
+ ...opts,
89
+ });
90
+ this.name = "ConflictException";
91
+ this.$fault = "client";
92
+ Object.setPrototypeOf(this, ConflictException.prototype);
93
+ this.reason = opts.reason;
94
+ this.zonalShiftId = opts.zonalShiftId;
95
+ }
96
+ }
97
+ export class ResourceNotFoundException extends __BaseException {
98
+ constructor(opts) {
99
+ super({
100
+ name: "ResourceNotFoundException",
101
+ $fault: "client",
102
+ ...opts,
103
+ });
104
+ this.name = "ResourceNotFoundException";
105
+ this.$fault = "client";
106
+ Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
107
+ }
108
+ }
95
109
  export const ZonalShiftStatus = {
96
110
  ACTIVE: "ACTIVE",
97
111
  CANCELED: "CANCELED",
98
112
  EXPIRED: "EXPIRED",
99
113
  };
114
+ export const ControlConditionType = {
115
+ CLOUDWATCH: "CLOUDWATCH",
116
+ };
117
+ export const ZonalAutoshiftStatus = {
118
+ DISABLED: "DISABLED",
119
+ ENABLED: "ENABLED",
120
+ };
121
+ export const PracticeRunOutcome = {
122
+ FAILED: "FAILED",
123
+ INTERRUPTED: "INTERRUPTED",
124
+ PENDING: "PENDING",
125
+ SUCCEEDED: "SUCCEEDED",
126
+ };
@@ -0,0 +1,25 @@
1
+ import { ARCZonalShiftClient } from "../ARCZonalShiftClient";
2
+ import { ListAutoshiftsCommand, } from "../commands/ListAutoshiftsCommand";
3
+ const makePagedClientRequest = async (client, input, ...args) => {
4
+ return await client.send(new ListAutoshiftsCommand(input), ...args);
5
+ };
6
+ export async function* paginateListAutoshifts(config, input, ...additionalArguments) {
7
+ let token = config.startingToken || undefined;
8
+ let hasNext = true;
9
+ let page;
10
+ while (hasNext) {
11
+ input.nextToken = token;
12
+ input["maxResults"] = config.pageSize;
13
+ if (config.client instanceof ARCZonalShiftClient) {
14
+ page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
+ }
16
+ else {
17
+ throw new Error("Invalid client, expected ARCZonalShift | ARCZonalShiftClient");
18
+ }
19
+ yield page;
20
+ const prevToken = token;
21
+ token = page.nextToken;
22
+ hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
+ }
24
+ return undefined;
25
+ }
@@ -1,3 +1,4 @@
1
1
  export * from "./Interfaces";
2
+ export * from "./ListAutoshiftsPaginator";
2
3
  export * from "./ListManagedResourcesPaginator";
3
4
  export * from "./ListZonalShiftsPaginator";