@ludeo/cloud-common 1.1.36 → 1.1.38

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.
@@ -4,6 +4,7 @@ export * from "./allocate-machine-request";
4
4
  export * from "./create-game-resource-request";
5
5
  export * from "./create-games-request";
6
6
  export * from "./create-machine-resource-batch-request";
7
+ export * from "./create-machine-resource-request";
7
8
  export * from "./create-machines-request";
8
9
  export * from "./deallocate-machine-request";
9
10
  export * from "./game-resource-allocated-response";
@@ -16,6 +17,7 @@ export * from "./machine-allocated-response";
16
17
  export * from "./machine-allocation-failed-response";
17
18
  export * from "./machine-deallocated-response";
18
19
  export * from "./machine-deallocation-failed-response";
20
+ export * from "./machine-pool-resizing-task";
19
21
  export * from "./machine-resource-created-response";
20
22
  export * from "./machine-resource-creation-failed-response";
21
23
  export * from "./set-pool.event";
@@ -20,6 +20,7 @@ __exportStar(require("./allocate-machine-request"), exports);
20
20
  __exportStar(require("./create-game-resource-request"), exports);
21
21
  __exportStar(require("./create-games-request"), exports);
22
22
  __exportStar(require("./create-machine-resource-batch-request"), exports);
23
+ __exportStar(require("./create-machine-resource-request"), exports);
23
24
  __exportStar(require("./create-machines-request"), exports);
24
25
  __exportStar(require("./deallocate-machine-request"), exports);
25
26
  __exportStar(require("./game-resource-allocated-response"), exports);
@@ -32,6 +33,7 @@ __exportStar(require("./machine-allocated-response"), exports);
32
33
  __exportStar(require("./machine-allocation-failed-response"), exports);
33
34
  __exportStar(require("./machine-deallocated-response"), exports);
34
35
  __exportStar(require("./machine-deallocation-failed-response"), exports);
36
+ __exportStar(require("./machine-pool-resizing-task"), exports);
35
37
  __exportStar(require("./machine-resource-created-response"), exports);
36
38
  __exportStar(require("./machine-resource-creation-failed-response"), exports);
37
39
  __exportStar(require("./set-pool.event"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v3/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0DAAwC;AACxC,mEAAiD;AACjD,6DAA2C;AAC3C,iEAA+C;AAC/C,yDAAuC;AACvC,0EAAwD;AACxD,4DAA0C;AAC1C,+DAA6C;AAC7C,qEAAmD;AACnD,6EAA2D;AAC3D,mEAAiD;AACjD,2EAAyD;AACzD,sEAAoD;AACpD,8EAA4D;AAC5D,+DAA6C;AAC7C,uEAAqD;AACrD,iEAA+C;AAC/C,yEAAuD;AACvD,sEAAoD;AACpD,8EAA4D;AAC5D,mDAAiC;AACjC,oEAAkD;AAClD,4DAA0C;AAC1C,6EAA2D;AAC3D,+DAA6C;AAC7C,4DAA0C;AAC1C,mEAAiD;AACjD,+DAA6C;AAC7C,sEAAoD;AACpD,yDAAuC;AACvC,8DAA4C;AAC5C,6DAA2C"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v3/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0DAAwC;AACxC,mEAAiD;AACjD,6DAA2C;AAC3C,iEAA+C;AAC/C,yDAAuC;AACvC,0EAAwD;AACxD,oEAAkD;AAClD,4DAA0C;AAC1C,+DAA6C;AAC7C,qEAAmD;AACnD,6EAA2D;AAC3D,mEAAiD;AACjD,2EAAyD;AACzD,sEAAoD;AACpD,8EAA4D;AAC5D,+DAA6C;AAC7C,uEAAqD;AACrD,iEAA+C;AAC/C,yEAAuD;AACvD,+DAA6C;AAC7C,sEAAoD;AACpD,8EAA4D;AAC5D,mDAAiC;AACjC,oEAAkD;AAClD,4DAA0C;AAC1C,6EAA2D;AAC3D,+DAA6C;AAC7C,4DAA0C;AAC1C,mEAAiD;AACjD,+DAA6C;AAC7C,sEAAoD;AACpD,yDAAuC;AACvC,8DAA4C;AAC5C,6DAA2C"}
@@ -0,0 +1,13 @@
1
+ import { LudeoEvent } from "../../infra/ludeo-event";
2
+ import { CloudProvider, CloudProviderSettings } from "../types";
3
+ export declare class MachinePoolResizingTaskEventPayload {
4
+ providerSettings: CloudProviderSettings;
5
+ cloudProvider: CloudProvider;
6
+ machinePoolId: string;
7
+ }
8
+ export declare class MachinePoolResizingTask extends LudeoEvent {
9
+ static readonly EVENT_NAME = "cloud-resources.machine-pool-resizing-task";
10
+ constructor(payload: MachinePoolResizingTaskEventPayload, context: never);
11
+ context: never;
12
+ payload: MachinePoolResizingTaskEventPayload;
13
+ }
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.MachinePoolResizingTask = exports.MachinePoolResizingTaskEventPayload = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const ludeo_event_1 = require("../../infra/ludeo-event");
15
+ const decorators_1 = require("../../decorators");
16
+ const types_1 = require("../types");
17
+ class MachinePoolResizingTaskEventPayload {
18
+ }
19
+ exports.MachinePoolResizingTaskEventPayload = MachinePoolResizingTaskEventPayload;
20
+ __decorate([
21
+ (0, decorators_1.ValidateNestedType)(() => types_1.AWSProviderSettings),
22
+ __metadata("design:type", Object)
23
+ ], MachinePoolResizingTaskEventPayload.prototype, "providerSettings", void 0);
24
+ __decorate([
25
+ (0, class_validator_1.IsEnum)(types_1.CloudProvider),
26
+ __metadata("design:type", String)
27
+ ], MachinePoolResizingTaskEventPayload.prototype, "cloudProvider", void 0);
28
+ __decorate([
29
+ (0, class_validator_1.IsUUID)(),
30
+ __metadata("design:type", String)
31
+ ], MachinePoolResizingTaskEventPayload.prototype, "machinePoolId", void 0);
32
+ class MachinePoolResizingTask extends ludeo_event_1.LudeoEvent {
33
+ constructor(payload, context) {
34
+ super(MachinePoolResizingTask.EVENT_NAME);
35
+ this.payload = payload;
36
+ this.context = context;
37
+ }
38
+ }
39
+ exports.MachinePoolResizingTask = MachinePoolResizingTask;
40
+ MachinePoolResizingTask.EVENT_NAME = "cloud-resources.machine-pool-resizing-task";
41
+ __decorate([
42
+ (0, decorators_1.ValidateNestedType)(() => MachinePoolResizingTaskEventPayload),
43
+ __metadata("design:type", MachinePoolResizingTaskEventPayload)
44
+ ], MachinePoolResizingTask.prototype, "payload", void 0);
45
+ //# sourceMappingURL=machine-pool-resizing-task.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"machine-pool-resizing-task.js","sourceRoot":"","sources":["../../../src/v3/events/machine-pool-resizing-task.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAiD;AACjD,yDAAqD;AACrD,iDAAsD;AACtD,oCAIkB;AAElB,MAAa,mCAAmC;CAS/C;AATD,kFASC;AAPC;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,2BAAmB,CAAC;;6EACN;AAGxC;IADC,IAAA,wBAAM,EAAC,qBAAa,CAAC;;0EACO;AAG7B;IADC,IAAA,wBAAM,GAAE;;0EACa;AAGxB,MAAa,uBAAwB,SAAQ,wBAAU;IAIrD,YAAY,OAA4C,EAAE,OAAc;QACtE,KAAK,CAAC,uBAAuB,CAAC,UAAU,CAAC,CAAC;QAC1C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AARH,0DAcC;AAbwB,kCAAU,GAC/B,4CAA4C,CAAC;AAWxC;IADN,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,mCAAmC,CAAC;8BAC9C,mCAAmC;wDAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ludeo/cloud-common",
3
- "version": "1.1.36",
3
+ "version": "1.1.38",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "author": "Yahil Didi",
@@ -4,6 +4,7 @@ export * from "./allocate-machine-request";
4
4
  export * from "./create-game-resource-request";
5
5
  export * from "./create-games-request";
6
6
  export * from "./create-machine-resource-batch-request";
7
+ export * from "./create-machine-resource-request";
7
8
  export * from "./create-machines-request";
8
9
  export * from "./deallocate-machine-request";
9
10
  export * from "./game-resource-allocated-response";
@@ -16,6 +17,7 @@ export * from "./machine-allocated-response";
16
17
  export * from "./machine-allocation-failed-response";
17
18
  export * from "./machine-deallocated-response";
18
19
  export * from "./machine-deallocation-failed-response";
20
+ export * from "./machine-pool-resizing-task";
19
21
  export * from "./machine-resource-created-response";
20
22
  export * from "./machine-resource-creation-failed-response";
21
23
  export * from "./set-pool.event";
@@ -0,0 +1,35 @@
1
+ import { IsEnum, IsUUID } from "class-validator";
2
+ import { LudeoEvent } from "../../infra/ludeo-event";
3
+ import { ValidateNestedType } from "../../decorators";
4
+ import {
5
+ AWSProviderSettings,
6
+ CloudProvider,
7
+ CloudProviderSettings,
8
+ } from "../types";
9
+
10
+ export class MachinePoolResizingTaskEventPayload {
11
+ @ValidateNestedType(() => AWSProviderSettings)
12
+ providerSettings: CloudProviderSettings;
13
+
14
+ @IsEnum(CloudProvider)
15
+ cloudProvider: CloudProvider;
16
+
17
+ @IsUUID()
18
+ machinePoolId: string;
19
+ }
20
+
21
+ export class MachinePoolResizingTask extends LudeoEvent {
22
+ public static readonly EVENT_NAME =
23
+ "cloud-resources.machine-pool-resizing-task";
24
+
25
+ constructor(payload: MachinePoolResizingTaskEventPayload, context: never) {
26
+ super(MachinePoolResizingTask.EVENT_NAME);
27
+ this.payload = payload;
28
+ this.context = context;
29
+ }
30
+
31
+ public context: never;
32
+
33
+ @ValidateNestedType(() => MachinePoolResizingTaskEventPayload)
34
+ public payload: MachinePoolResizingTaskEventPayload;
35
+ }