@ludeo/cloud-common 1.1.99 → 1.1.101-beta1
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 +2 -0
- package/dist/v3/events/index.js +2 -0
- package/dist/v3/events/index.js.map +1 -1
- package/dist/v3/events/terminate-stale-games.d.ts +11 -0
- package/dist/v3/events/terminate-stale-games.js +41 -0
- package/dist/v3/events/terminate-stale-games.js.map +1 -0
- package/dist/v3/events/terminate-stale-machines.d.ts +11 -0
- package/dist/v3/events/terminate-stale-machines.js +41 -0
- package/dist/v3/events/terminate-stale-machines.js.map +1 -0
- package/dist/v3/types/pools/configuration/base.d.ts +0 -1
- package/dist/v3/types/pools/configuration/base.js +0 -5
- package/dist/v3/types/pools/configuration/base.js.map +1 -1
- package/package.json +1 -1
- package/src/v3/events/index.ts +2 -0
- package/src/v3/events/terminate-stale-games.ts +28 -0
- package/src/v3/events/terminate-stale-machines.ts +28 -0
- package/src/v3/types/pools/configuration/base.ts +0 -4
|
@@ -43,6 +43,8 @@ export * from "./terminate-games-request";
|
|
|
43
43
|
export * from "./terminate-machine-resource-request";
|
|
44
44
|
export * from "./terminate-machine-resource-batch-request";
|
|
45
45
|
export * from "./terminate-machines-request";
|
|
46
|
+
export * from "./terminate-stale-games";
|
|
47
|
+
export * from "./terminate-stale-machines";
|
|
46
48
|
export * from "./prepare-cloud-machine-auth";
|
|
47
49
|
export * from "./prepare-cloud-machine-auth-failed";
|
|
48
50
|
export * from "./token-required.event";
|
package/dist/v3/events/index.js
CHANGED
|
@@ -59,6 +59,8 @@ __exportStar(require("./terminate-games-request"), exports);
|
|
|
59
59
|
__exportStar(require("./terminate-machine-resource-request"), exports);
|
|
60
60
|
__exportStar(require("./terminate-machine-resource-batch-request"), exports);
|
|
61
61
|
__exportStar(require("./terminate-machines-request"), exports);
|
|
62
|
+
__exportStar(require("./terminate-stale-games"), exports);
|
|
63
|
+
__exportStar(require("./terminate-stale-machines"), exports);
|
|
62
64
|
__exportStar(require("./prepare-cloud-machine-auth"), exports);
|
|
63
65
|
__exportStar(require("./prepare-cloud-machine-auth-failed"), exports);
|
|
64
66
|
__exportStar(require("./token-required.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,oEAAkD;AAClD,4DAA0C;AAC1C,+DAA6C;AAC7C,4DAA0C;AAC1C,oEAAkD;AAClD,qEAAmD;AACnD,6EAA2D;AAC3D,mEAAiD;AACjD,2EAAyD;AACzD,sEAAoD;AACpD,8EAA4D;AAC5D,6DAA2C;AAC3C,qEAAmD;AACnD,iEAA+C;AAC/C,+DAA6C;AAC7C,uEAAqD;AACrD,iEAA+C;AAC/C,yEAAuD;AACvD,+DAA6C;AAC7C,oFAAkE;AAClE,uFAAqE;AACrE,sEAAoD;AACpD,8EAA4D;AAC5D,yEAAuD;AACvD,6DAA2C;AAC3C,+DAA6C;AAC7C,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;AAC3C,kEAAgD;AAChD,+DAA6C;AAC7C,gEAA8C;AAC9C,oEAAkD;AAClD,0DAAwC;AACxC,4DAA0C"}
|
|
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,4DAA0C;AAC1C,oEAAkD;AAClD,qEAAmD;AACnD,6EAA2D;AAC3D,mEAAiD;AACjD,2EAAyD;AACzD,sEAAoD;AACpD,8EAA4D;AAC5D,6DAA2C;AAC3C,qEAAmD;AACnD,iEAA+C;AAC/C,+DAA6C;AAC7C,uEAAqD;AACrD,iEAA+C;AAC/C,yEAAuD;AACvD,+DAA6C;AAC7C,oFAAkE;AAClE,uFAAqE;AACrE,sEAAoD;AACpD,8EAA4D;AAC5D,yEAAuD;AACvD,6DAA2C;AAC3C,+DAA6C;AAC7C,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,0DAAwC;AACxC,6DAA2C;AAC3C,+DAA6C;AAC7C,sEAAoD;AACpD,yDAAuC;AACvC,6DAA2C;AAC3C,kEAAgD;AAChD,+DAA6C;AAC7C,gEAA8C;AAC9C,oEAAkD;AAClD,0DAAwC;AACxC,4DAA0C"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
2
|
+
import { CloudPoolContext } from "../contexts";
|
|
3
|
+
export declare class TerminateStaleGamesRequestPayload {
|
|
4
|
+
poolId: string;
|
|
5
|
+
}
|
|
6
|
+
export declare class TerminateStaleGames extends LudeoEvent {
|
|
7
|
+
static readonly EVENT_NAME = "cloud-pools.terminate-stale-games";
|
|
8
|
+
constructor(payload: TerminateStaleGamesRequestPayload, context: CloudPoolContext);
|
|
9
|
+
context: CloudPoolContext;
|
|
10
|
+
payload: TerminateStaleGamesRequestPayload;
|
|
11
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
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.TerminateStaleGames = exports.TerminateStaleGamesRequestPayload = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
const ludeo_event_1 = require("../../infra/ludeo-event");
|
|
15
|
+
const contexts_1 = require("../contexts");
|
|
16
|
+
const decorators_1 = require("../../decorators");
|
|
17
|
+
class TerminateStaleGamesRequestPayload {
|
|
18
|
+
}
|
|
19
|
+
exports.TerminateStaleGamesRequestPayload = TerminateStaleGamesRequestPayload;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, class_validator_1.IsString)(),
|
|
22
|
+
__metadata("design:type", String)
|
|
23
|
+
], TerminateStaleGamesRequestPayload.prototype, "poolId", void 0);
|
|
24
|
+
class TerminateStaleGames extends ludeo_event_1.LudeoEvent {
|
|
25
|
+
constructor(payload, context) {
|
|
26
|
+
super(TerminateStaleGames.EVENT_NAME);
|
|
27
|
+
this.payload = payload;
|
|
28
|
+
this.context = context;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
exports.TerminateStaleGames = TerminateStaleGames;
|
|
32
|
+
TerminateStaleGames.EVENT_NAME = "cloud-pools.terminate-stale-games";
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, decorators_1.ValidateNestedType)(() => contexts_1.CloudPoolContext),
|
|
35
|
+
__metadata("design:type", contexts_1.CloudPoolContext)
|
|
36
|
+
], TerminateStaleGames.prototype, "context", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, decorators_1.ValidateNestedType)(() => TerminateStaleGamesRequestPayload),
|
|
39
|
+
__metadata("design:type", TerminateStaleGamesRequestPayload)
|
|
40
|
+
], TerminateStaleGames.prototype, "payload", void 0);
|
|
41
|
+
//# sourceMappingURL=terminate-stale-games.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"terminate-stale-games.js","sourceRoot":"","sources":["../../../src/v3/events/terminate-stale-games.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA2C;AAC3C,yDAAqD;AACrD,0CAA+C;AAC/C,iDAAsD;AAEtD,MAAa,iCAAiC;CAG7C;AAHD,8EAGC;AADC;IADC,IAAA,0BAAQ,GAAE;;iEACI;AAGjB,MAAa,mBAAoB,SAAQ,wBAAU;IAGjD,YACE,OAA0C,EAC1C,OAAyB;QAEzB,KAAK,CAAC,mBAAmB,CAAC,UAAU,CAAC,CAAC;QACtC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,kDAiBC;AAhBiB,8BAAU,GAAG,mCAAmC,CAAC;AAYjE;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,2BAAgB,CAAC;8BAClC,2BAAgB;oDAAC;AAG1B;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,iCAAiC,CAAC;8BACnD,iCAAiC;oDAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
2
|
+
import { CloudPoolContext } from "../contexts";
|
|
3
|
+
export declare class TerminateStaleMachinesRequestPayload {
|
|
4
|
+
poolId: string;
|
|
5
|
+
}
|
|
6
|
+
export declare class TerminateStaleMachines extends LudeoEvent {
|
|
7
|
+
static readonly EVENT_NAME = "cloud-pools.terminate-stale-machines";
|
|
8
|
+
constructor(payload: TerminateStaleMachinesRequestPayload, context: CloudPoolContext);
|
|
9
|
+
context: CloudPoolContext;
|
|
10
|
+
payload: TerminateStaleMachinesRequestPayload;
|
|
11
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
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.TerminateStaleMachines = exports.TerminateStaleMachinesRequestPayload = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
const ludeo_event_1 = require("../../infra/ludeo-event");
|
|
15
|
+
const contexts_1 = require("../contexts");
|
|
16
|
+
const decorators_1 = require("../../decorators");
|
|
17
|
+
class TerminateStaleMachinesRequestPayload {
|
|
18
|
+
}
|
|
19
|
+
exports.TerminateStaleMachinesRequestPayload = TerminateStaleMachinesRequestPayload;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, class_validator_1.IsString)(),
|
|
22
|
+
__metadata("design:type", String)
|
|
23
|
+
], TerminateStaleMachinesRequestPayload.prototype, "poolId", void 0);
|
|
24
|
+
class TerminateStaleMachines extends ludeo_event_1.LudeoEvent {
|
|
25
|
+
constructor(payload, context) {
|
|
26
|
+
super(TerminateStaleMachines.EVENT_NAME);
|
|
27
|
+
this.payload = payload;
|
|
28
|
+
this.context = context;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
exports.TerminateStaleMachines = TerminateStaleMachines;
|
|
32
|
+
TerminateStaleMachines.EVENT_NAME = "cloud-pools.terminate-stale-machines";
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, decorators_1.ValidateNestedType)(() => contexts_1.CloudPoolContext),
|
|
35
|
+
__metadata("design:type", contexts_1.CloudPoolContext)
|
|
36
|
+
], TerminateStaleMachines.prototype, "context", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, decorators_1.ValidateNestedType)(() => TerminateStaleMachinesRequestPayload),
|
|
39
|
+
__metadata("design:type", TerminateStaleMachinesRequestPayload)
|
|
40
|
+
], TerminateStaleMachines.prototype, "payload", void 0);
|
|
41
|
+
//# sourceMappingURL=terminate-stale-machines.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"terminate-stale-machines.js","sourceRoot":"","sources":["../../../src/v3/events/terminate-stale-machines.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA2C;AAC3C,yDAAqD;AACrD,0CAA+C;AAC/C,iDAAsD;AAEtD,MAAa,oCAAoC;CAGhD;AAHD,oFAGC;AADC;IADC,IAAA,0BAAQ,GAAE;;oEACI;AAGjB,MAAa,sBAAuB,SAAQ,wBAAU;IAGpD,YACE,OAA6C,EAC7C,OAAyB;QAEzB,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,+BAAkB,EAAC,GAAG,EAAE,CAAC,2BAAgB,CAAC;8BAClC,2BAAgB;uDAAC;AAG1B;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,oCAAoC,CAAC;8BACtD,oCAAoC;uDAAC"}
|
|
@@ -50,9 +50,4 @@ __decorate([
|
|
|
50
50
|
(0, decorators_1.ValidateNestedType)(() => attributes_1.BasePoolAttributes),
|
|
51
51
|
__metadata("design:type", attributes_1.BasePoolAttributes)
|
|
52
52
|
], BaseCloudPoolConfiguration.prototype, "attributes", void 0);
|
|
53
|
-
__decorate([
|
|
54
|
-
(0, class_validator_1.IsOptional)(),
|
|
55
|
-
(0, class_validator_1.IsUUID)(),
|
|
56
|
-
__metadata("design:type", String)
|
|
57
|
-
], BaseCloudPoolConfiguration.prototype, "lastPredictorRequestId", void 0);
|
|
58
53
|
//# sourceMappingURL=base.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base.js","sourceRoot":"","sources":["../../../../../src/v3/types/pools/configuration/base.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAuE;AAEvE,uCAIqB;AACrB,kCAAwC;AACxC,6CAAkD;AAClD,uDAA4D;AAE5D,MAAa,sBAAsB;CAGlC;AAHD,wDAGC;AADC;IADC,IAAA,0BAAQ,GAAE;;oDACE;AAGf,MAAa,0BAA0B;
|
|
1
|
+
{"version":3,"file":"base.js","sourceRoot":"","sources":["../../../../../src/v3/types/pools/configuration/base.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAuE;AAEvE,uCAIqB;AACrB,kCAAwC;AACxC,6CAAkD;AAClD,uDAA4D;AAE5D,MAAa,sBAAsB;CAGlC;AAHD,wDAGC;AADC;IADC,IAAA,0BAAQ,GAAE;;oDACE;AAGf,MAAa,0BAA0B;CAmBtC;AAnBD,gEAmBC;AAhBC;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,2BAAmB,CAAC;;oEACL;AAGzC;IADC,IAAA,wBAAM,EAAC,qBAAa,CAAC;;iEACO;AAG7B;IADC,IAAA,wBAAM,GAAE;;0DACM;AAGf;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,sBAAsB,CAAC;8BACzB,sBAAsB;0EAAC;AAG/C;IADC,IAAA,wBAAM,EAAC,oBAAa,CAAC;;wDACF;AAGpB;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,+BAAkB,CAAC;8BACjC,+BAAkB;8DAAC"}
|
package/package.json
CHANGED
package/src/v3/events/index.ts
CHANGED
|
@@ -43,6 +43,8 @@ export * from "./terminate-games-request";
|
|
|
43
43
|
export * from "./terminate-machine-resource-request";
|
|
44
44
|
export * from "./terminate-machine-resource-batch-request";
|
|
45
45
|
export * from "./terminate-machines-request";
|
|
46
|
+
export * from "./terminate-stale-games";
|
|
47
|
+
export * from "./terminate-stale-machines";
|
|
46
48
|
export * from "./prepare-cloud-machine-auth";
|
|
47
49
|
export * from "./prepare-cloud-machine-auth-failed";
|
|
48
50
|
export * from "./token-required.event";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { IsString } from "class-validator";
|
|
2
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
3
|
+
import { CloudPoolContext } from "../contexts";
|
|
4
|
+
import { ValidateNestedType } from "../../decorators";
|
|
5
|
+
|
|
6
|
+
export class TerminateStaleGamesRequestPayload {
|
|
7
|
+
@IsString()
|
|
8
|
+
poolId: string;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export class TerminateStaleGames extends LudeoEvent {
|
|
12
|
+
static readonly EVENT_NAME = "cloud-pools.terminate-stale-games";
|
|
13
|
+
|
|
14
|
+
constructor(
|
|
15
|
+
payload: TerminateStaleGamesRequestPayload,
|
|
16
|
+
context: CloudPoolContext
|
|
17
|
+
) {
|
|
18
|
+
super(TerminateStaleGames.EVENT_NAME);
|
|
19
|
+
this.payload = payload;
|
|
20
|
+
this.context = context;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
@ValidateNestedType(() => CloudPoolContext)
|
|
24
|
+
context: CloudPoolContext;
|
|
25
|
+
|
|
26
|
+
@ValidateNestedType(() => TerminateStaleGamesRequestPayload)
|
|
27
|
+
payload: TerminateStaleGamesRequestPayload;
|
|
28
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { IsString } from "class-validator";
|
|
2
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
3
|
+
import { CloudPoolContext } from "../contexts";
|
|
4
|
+
import { ValidateNestedType } from "../../decorators";
|
|
5
|
+
|
|
6
|
+
export class TerminateStaleMachinesRequestPayload {
|
|
7
|
+
@IsString()
|
|
8
|
+
poolId: string;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export class TerminateStaleMachines extends LudeoEvent {
|
|
12
|
+
static readonly EVENT_NAME = "cloud-pools.terminate-stale-machines";
|
|
13
|
+
|
|
14
|
+
constructor(
|
|
15
|
+
payload: TerminateStaleMachinesRequestPayload,
|
|
16
|
+
context: CloudPoolContext
|
|
17
|
+
) {
|
|
18
|
+
super(TerminateStaleMachines.EVENT_NAME);
|
|
19
|
+
this.payload = payload;
|
|
20
|
+
this.context = context;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
@ValidateNestedType(() => CloudPoolContext)
|
|
24
|
+
context: CloudPoolContext;
|
|
25
|
+
|
|
26
|
+
@ValidateNestedType(() => TerminateStaleMachinesRequestPayload)
|
|
27
|
+
payload: TerminateStaleMachinesRequestPayload;
|
|
28
|
+
}
|