@ludeo/cloud-common 1.1.92 → 1.1.93
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/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/v3/events/index.d.ts +1 -0
- package/dist/v3/events/index.js +1 -0
- package/dist/v3/events/index.js.map +1 -1
- package/dist/v3/events/machine-resource-updated.d.ts +12 -0
- package/dist/v3/events/machine-resource-updated.js +45 -0
- package/dist/v3/events/machine-resource-updated.js.map +1 -0
- package/package.json +1 -1
- package/src/v3/events/index.ts +1 -0
- package/src/v3/events/machine-resource-updated.ts +32 -0
|
@@ -28,6 +28,7 @@ export * from "./machine-resource-batch-termination-failed-response";
|
|
|
28
28
|
export * from "./machine-resource-created-response";
|
|
29
29
|
export * from "./machine-resource-creation-failed-response";
|
|
30
30
|
export * from "./machine-resource-terminated-response";
|
|
31
|
+
export * from "./machine-resource-updated";
|
|
31
32
|
export * from "./monitor-game-resource-task";
|
|
32
33
|
export * from "./pool-status";
|
|
33
34
|
export * from "./send-pools-to-predictor";
|
package/dist/v3/events/index.js
CHANGED
|
@@ -44,6 +44,7 @@ __exportStar(require("./machine-resource-batch-termination-failed-response"), ex
|
|
|
44
44
|
__exportStar(require("./machine-resource-created-response"), exports);
|
|
45
45
|
__exportStar(require("./machine-resource-creation-failed-response"), exports);
|
|
46
46
|
__exportStar(require("./machine-resource-terminated-response"), exports);
|
|
47
|
+
__exportStar(require("./machine-resource-updated"), exports);
|
|
47
48
|
__exportStar(require("./monitor-game-resource-task"), exports);
|
|
48
49
|
__exportStar(require("./pool-status"), exports);
|
|
49
50
|
__exportStar(require("./send-pools-to-predictor"), 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,yD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7C,gDAA8B;AAC9B,4DAA0C;AAC1C,6CAA2B;AAC3B,oDAAkC;AAClC,8DAA4C;AAC5C,mEAAiD;AACjD,4DAA0C;AAC1C,2DAAyC;AACzC,oEAAkD;AAClD,4DAA0C;AAC1C,uEAAqD;AACrD,6EAA2D;AAC3D,+DAA6C;AAC7C,+DAA6C;AAC7C,sEAAoD;AACpD,yDAAuC;AACvC,6DAA2C"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { CloudResourceContext } from "../contexts";
|
|
2
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
3
|
+
export declare class MachineResourceUpdatedPayload {
|
|
4
|
+
machineResourceId: string;
|
|
5
|
+
machinePoolId: string;
|
|
6
|
+
}
|
|
7
|
+
export declare class MachineResourceUpdated extends LudeoEvent {
|
|
8
|
+
static readonly EVENT_NAME = "cloud-pools.machine-resource-updated";
|
|
9
|
+
constructor(payload: MachineResourceUpdatedPayload, context: CloudResourceContext);
|
|
10
|
+
context: CloudResourceContext;
|
|
11
|
+
payload: MachineResourceUpdatedPayload;
|
|
12
|
+
}
|
|
@@ -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.MachineResourceUpdated = exports.MachineResourceUpdatedPayload = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
const contexts_1 = require("../contexts");
|
|
15
|
+
const ludeo_event_1 = require("../../infra/ludeo-event");
|
|
16
|
+
const validate_nested_type_decorator_1 = require("../../decorators/validate-nested-type.decorator");
|
|
17
|
+
class MachineResourceUpdatedPayload {
|
|
18
|
+
}
|
|
19
|
+
exports.MachineResourceUpdatedPayload = MachineResourceUpdatedPayload;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, class_validator_1.IsUUID)(),
|
|
22
|
+
__metadata("design:type", String)
|
|
23
|
+
], MachineResourceUpdatedPayload.prototype, "machineResourceId", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_validator_1.IsUUID)(),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], MachineResourceUpdatedPayload.prototype, "machinePoolId", void 0);
|
|
28
|
+
class MachineResourceUpdated extends ludeo_event_1.LudeoEvent {
|
|
29
|
+
constructor(payload, context) {
|
|
30
|
+
super(MachineResourceUpdated.EVENT_NAME);
|
|
31
|
+
this.payload = payload;
|
|
32
|
+
this.context = context;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
exports.MachineResourceUpdated = MachineResourceUpdated;
|
|
36
|
+
MachineResourceUpdated.EVENT_NAME = "cloud-pools.machine-resource-updated";
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => contexts_1.CloudResourceContext),
|
|
39
|
+
__metadata("design:type", contexts_1.CloudResourceContext)
|
|
40
|
+
], MachineResourceUpdated.prototype, "context", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => MachineResourceUpdatedPayload),
|
|
43
|
+
__metadata("design:type", MachineResourceUpdatedPayload)
|
|
44
|
+
], MachineResourceUpdated.prototype, "payload", void 0);
|
|
45
|
+
//# sourceMappingURL=machine-resource-updated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"machine-resource-updated.js","sourceRoot":"","sources":["../../../src/v3/events/machine-resource-updated.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAyC;AAEzC,0CAAmD;AACnD,yDAAqD;AACrD,oGAAqF;AAErF,MAAa,6BAA6B;CAMzC;AAND,sEAMC;AAJC;IADC,IAAA,wBAAM,GAAE;;wEACiB;AAG1B;IADC,IAAA,wBAAM,GAAE;;oEACa;AAGxB,MAAa,sBAAuB,SAAQ,wBAAU;IAGpD,YACE,OAAsC,EACtC,OAA6B;QAE7B,KAAK,CAAC,sBAAsB,CAAC,UAAU,CAAC,CAAC;QACzC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,wDAiBC;AAhBiB,iCAAU,GAAG,sCAAsC,CAAC;AAYpE;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,+BAAoB,CAAC;8BACtC,+BAAoB;uDAAC;AAG9B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,6BAA6B,CAAC;8BAC/C,6BAA6B;uDAAC"}
|
package/package.json
CHANGED
package/src/v3/events/index.ts
CHANGED
|
@@ -28,6 +28,7 @@ export * from "./machine-resource-batch-termination-failed-response";
|
|
|
28
28
|
export * from "./machine-resource-created-response";
|
|
29
29
|
export * from "./machine-resource-creation-failed-response";
|
|
30
30
|
export * from "./machine-resource-terminated-response";
|
|
31
|
+
export * from "./machine-resource-updated";
|
|
31
32
|
export * from "./monitor-game-resource-task";
|
|
32
33
|
export * from "./pool-status";
|
|
33
34
|
export * from "./send-pools-to-predictor";
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { IsUUID } from "class-validator";
|
|
2
|
+
|
|
3
|
+
import { CloudResourceContext } from "../contexts";
|
|
4
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
5
|
+
import { ValidateNestedType } from "../../decorators/validate-nested-type.decorator";
|
|
6
|
+
|
|
7
|
+
export class MachineResourceUpdatedPayload {
|
|
8
|
+
@IsUUID()
|
|
9
|
+
machineResourceId: string;
|
|
10
|
+
|
|
11
|
+
@IsUUID()
|
|
12
|
+
machinePoolId: string;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export class MachineResourceUpdated extends LudeoEvent {
|
|
16
|
+
static readonly EVENT_NAME = "cloud-pools.machine-resource-updated";
|
|
17
|
+
|
|
18
|
+
constructor(
|
|
19
|
+
payload: MachineResourceUpdatedPayload,
|
|
20
|
+
context: CloudResourceContext
|
|
21
|
+
) {
|
|
22
|
+
super(MachineResourceUpdated.EVENT_NAME);
|
|
23
|
+
this.payload = payload;
|
|
24
|
+
this.context = context;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
@ValidateNestedType(() => CloudResourceContext)
|
|
28
|
+
context: CloudResourceContext;
|
|
29
|
+
|
|
30
|
+
@ValidateNestedType(() => MachineResourceUpdatedPayload)
|
|
31
|
+
payload: MachineResourceUpdatedPayload;
|
|
32
|
+
}
|