@ludeo/cloud-common 1.2.27 → 1.2.29

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.
@@ -70,3 +70,4 @@ export * from "./game-resource-ready-for-creation";
70
70
  export * from "./game-resource-ready-for-creation-failed";
71
71
  export * from "./aws-stream-session-active";
72
72
  export * from "./cloud-session-optimal-region-selected";
73
+ export * from "./mark-game-available";
@@ -86,4 +86,5 @@ __exportStar(require("./game-resource-ready-for-creation"), exports);
86
86
  __exportStar(require("./game-resource-ready-for-creation-failed"), exports);
87
87
  __exportStar(require("./aws-stream-session-active"), exports);
88
88
  __exportStar(require("./cloud-session-optimal-region-selected"), exports);
89
+ __exportStar(require("./mark-game-available"), exports);
89
90
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v3/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0DAAwC;AACxC,mEAAiD;AACjD,6DAA2C;AAC3C,uEAAqD;AACrD,4EAA0D;AAC1D,6DAA2C;AAC3C,qEAAmD;AACnD,iEAA+C;AAC/C,yDAAuC;AACvC,0EAAwD;AACxD,oEAAkD;AAClD,4DAA0C;AAC1C,+DAA6C;AAC7C,mDAAiC;AACjC,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,mEAAiD;AACjD,+DAA6C;AAC7C,gEAA8C;AAC9C,oEAAkD;AAClD,0DAAwC;AACxC,4DAA0C;AAC1C,mEAAiD;AACjD,wDAAsC;AACtC,0DAAwC;AACxC,0EAAwD;AACxD,iEAA+C;AAC/C,qEAAmD;AACnD,4EAA0D;AAC1D,8DAA4C;AAC5C,0EAAwD"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v3/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0DAAwC;AACxC,mEAAiD;AACjD,6DAA2C;AAC3C,uEAAqD;AACrD,4EAA0D;AAC1D,6DAA2C;AAC3C,qEAAmD;AACnD,iEAA+C;AAC/C,yDAAuC;AACvC,0EAAwD;AACxD,oEAAkD;AAClD,4DAA0C;AAC1C,+DAA6C;AAC7C,mDAAiC;AACjC,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,mEAAiD;AACjD,+DAA6C;AAC7C,gEAA8C;AAC9C,oEAAkD;AAClD,0DAAwC;AACxC,4DAA0C;AAC1C,mEAAiD;AACjD,wDAAsC;AACtC,0DAAwC;AACxC,0EAAwD;AACxD,iEAA+C;AAC/C,qEAAmD;AACnD,4EAA0D;AAC1D,8DAA4C;AAC5C,0EAAwD;AACxD,wDAAsC"}
@@ -0,0 +1,12 @@
1
+ import { LudeoEvent } from "../../infra/ludeo-event";
2
+ import { CloudSessionContext } from "../contexts";
3
+ export declare class MarkGameAvailablePayload {
4
+ gameResourceId: string;
5
+ gamePoolId: string;
6
+ }
7
+ export declare class MarkGameAvailable extends LudeoEvent {
8
+ static readonly EVENT_NAME = "cloud-sessions.mark-game-available";
9
+ constructor(payload: MarkGameAvailablePayload, context: CloudSessionContext);
10
+ context: CloudSessionContext;
11
+ payload: MarkGameAvailablePayload;
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.MarkGameAvailable = exports.MarkGameAvailablePayload = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const validate_nested_type_decorator_1 = require("../../decorators/validate-nested-type.decorator");
15
+ const ludeo_event_1 = require("../../infra/ludeo-event");
16
+ const contexts_1 = require("../contexts");
17
+ class MarkGameAvailablePayload {
18
+ }
19
+ exports.MarkGameAvailablePayload = MarkGameAvailablePayload;
20
+ __decorate([
21
+ (0, class_validator_1.IsUUID)(),
22
+ __metadata("design:type", String)
23
+ ], MarkGameAvailablePayload.prototype, "gameResourceId", void 0);
24
+ __decorate([
25
+ (0, class_validator_1.IsUUID)(),
26
+ __metadata("design:type", String)
27
+ ], MarkGameAvailablePayload.prototype, "gamePoolId", void 0);
28
+ class MarkGameAvailable extends ludeo_event_1.LudeoEvent {
29
+ constructor(payload, context) {
30
+ super(MarkGameAvailable.EVENT_NAME);
31
+ this.payload = payload;
32
+ this.context = context;
33
+ }
34
+ }
35
+ exports.MarkGameAvailable = MarkGameAvailable;
36
+ MarkGameAvailable.EVENT_NAME = "cloud-sessions.mark-game-available";
37
+ __decorate([
38
+ (0, validate_nested_type_decorator_1.ValidateNestedType)(() => contexts_1.CloudSessionContext),
39
+ __metadata("design:type", contexts_1.CloudSessionContext)
40
+ ], MarkGameAvailable.prototype, "context", void 0);
41
+ __decorate([
42
+ (0, validate_nested_type_decorator_1.ValidateNestedType)(() => MarkGameAvailablePayload),
43
+ __metadata("design:type", MarkGameAvailablePayload)
44
+ ], MarkGameAvailable.prototype, "payload", void 0);
45
+ //# sourceMappingURL=mark-game-available.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mark-game-available.js","sourceRoot":"","sources":["../../../src/v3/events/mark-game-available.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAyC;AAEzC,oGAAqF;AACrF,yDAAqD;AACrD,0CAAkD;AAElD,MAAa,wBAAwB;CAMpC;AAND,4DAMC;AAJC;IADC,IAAA,wBAAM,GAAE;;gEACc;AAGvB;IADC,IAAA,wBAAM,GAAE;;4DACU;AAGrB,MAAa,iBAAkB,SAAQ,wBAAU;IAG/C,YAAY,OAAiC,EAAE,OAA4B;QACzE,KAAK,CAAC,iBAAiB,CAAC,UAAU,CAAC,CAAC;QACpC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAPH,8CAcC;AAbiB,4BAAU,GAAG,oCAAoC,CAAC;AASlE;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,8BAAmB,CAAC;8BACrC,8BAAmB;kDAAC;AAG7B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,wBAAwB,CAAC;8BAC1C,wBAAwB;kDAAC"}
@@ -4,6 +4,7 @@ export declare class TerminateGameRequestPayload {
4
4
  gamePoolId?: string;
5
5
  gameResourceId: string;
6
6
  uploadLogs?: boolean;
7
+ reason?: string;
7
8
  }
8
9
  export declare class TerminateGameRequest extends LudeoEvent {
9
10
  static readonly EVENT_NAME = "cloud-session-allocator.terminate-game-request";
@@ -31,6 +31,11 @@ __decorate([
31
31
  (0, class_validator_1.IsOptional)(),
32
32
  __metadata("design:type", Boolean)
33
33
  ], TerminateGameRequestPayload.prototype, "uploadLogs", void 0);
34
+ __decorate([
35
+ (0, class_validator_1.IsOptional)(),
36
+ (0, class_validator_1.IsString)(),
37
+ __metadata("design:type", String)
38
+ ], TerminateGameRequestPayload.prototype, "reason", void 0);
34
39
  class TerminateGameRequest extends ludeo_event_1.LudeoEvent {
35
40
  constructor(payload, context) {
36
41
  super(TerminateGameRequest.EVENT_NAME);
@@ -1 +1 @@
1
- {"version":3,"file":"terminate-game-request.js","sourceRoot":"","sources":["../../../src/v3/events/terminate-game-request.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAgE;AAEhE,0CAIqB;AACrB,yDAAqD;AACrD,oGAAqF;AAErF,MAAa,2BAA2B;CAWvC;AAXD,kEAWC;AARC;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,wBAAM,GAAE;;+DACW;AAGpB;IADC,IAAA,wBAAM,GAAE;;mEACc;AAIvB;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,4BAAU,GAAE;;+DACQ;AAGvB,MAAa,oBAAqB,SAAQ,wBAAU;IAGlD,YACE,OAAoC,EACpC,OAAmD;QAEnD,KAAK,CAAC,oBAAoB,CAAC,UAAU,CAAC,CAAC;QACvC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,oDAiBC;AAhBiB,+BAAU,GAAG,gDAAgD,CAAC;AAY9E;IADC,IAAA,mDAAkB,EAAC,8BAAmB,CAAC;;qDACY;AAGpD;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,2BAA2B,CAAC;8BAC7C,2BAA2B;qDAAC"}
1
+ {"version":3,"file":"terminate-game-request.js","sourceRoot":"","sources":["../../../src/v3/events/terminate-game-request.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA0E;AAE1E,0CAIqB;AACrB,yDAAqD;AACrD,oGAAqF;AAErF,MAAa,2BAA2B;CAevC;AAfD,kEAeC;AAZC;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,wBAAM,GAAE;;+DACW;AAGpB;IADC,IAAA,wBAAM,GAAE;;mEACc;AAIvB;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,4BAAU,GAAE;;+DACQ;AAIrB;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAQ,GAAE;;2DACK;AAGlB,MAAa,oBAAqB,SAAQ,wBAAU;IAGlD,YACE,OAAoC,EACpC,OAAmD;QAEnD,KAAK,CAAC,oBAAoB,CAAC,UAAU,CAAC,CAAC;QACvC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,oDAiBC;AAhBiB,+BAAU,GAAG,gDAAgD,CAAC;AAY9E;IADC,IAAA,mDAAkB,EAAC,8BAAmB,CAAC;;qDACY;AAGpD;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,2BAA2B,CAAC;8BAC7C,2BAA2B;qDAAC"}
@@ -89,3 +89,4 @@ export * from "./ludeo-status-updated";
89
89
  export * from "./connection-id-timeout-task";
90
90
  export * from "./swap-to-default-user-request-failed";
91
91
  export * from "./cloud-session-stats-report";
92
+ export * from "./mark-game-available";
@@ -105,4 +105,5 @@ __exportStar(require("./ludeo-status-updated"), exports);
105
105
  __exportStar(require("./connection-id-timeout-task"), exports);
106
106
  __exportStar(require("./swap-to-default-user-request-failed"), exports);
107
107
  __exportStar(require("./cloud-session-stats-report"), exports);
108
+ __exportStar(require("./mark-game-available"), exports);
108
109
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v4/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0DAAwC;AACxC,mEAAiD;AACjD,6DAA2C;AAC3C,uEAAqD;AACrD,4EAA0D;AAC1D,6DAA2C;AAC3C,qEAAmD;AACnD,iEAA+C;AAC/C,yDAAuC;AACvC,0EAAwD;AACxD,oEAAkD;AAClD,4DAA0C;AAC1C,+DAA6C;AAC7C,mDAAiC;AACjC,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,mEAAiD;AACjD,+DAA6C;AAC7C,gEAA8C;AAC9C,oEAAkD;AAClD,0DAAwC;AACxC,4DAA0C;AAC1C,mEAAiD;AACjD,wDAAsC;AACtC,0DAAwC;AACxC,2EAAyD;AACzD,iEAA+C;AAC/C,qEAAmD;AACnD,4EAA0D;AAC1D,8DAA4C;AAC5C,0EAAwD;AACxD,0DAAwC;AACxC,oEAAkD;AAClD,8DAA4C;AAC5C,wDAAsC;AACtC,6DAA2C;AAC3C,4DAA0C;AAC1C,sEAAoD;AACpD,qEAAmD;AACnD,0DAAwC;AACxC,kEAAgD;AAChD,yDAAuC;AACvC,mEAAiD;AACjD,2DAAyC;AACzC,oEAAkD;AAClD,6DAA2C;AAC3C,yDAAuC;AACvC,+DAA6C;AAC7C,wEAAsD;AACtD,+DAA6C"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v4/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0DAAwC;AACxC,mEAAiD;AACjD,6DAA2C;AAC3C,uEAAqD;AACrD,4EAA0D;AAC1D,6DAA2C;AAC3C,qEAAmD;AACnD,iEAA+C;AAC/C,yDAAuC;AACvC,0EAAwD;AACxD,oEAAkD;AAClD,4DAA0C;AAC1C,+DAA6C;AAC7C,mDAAiC;AACjC,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,mEAAiD;AACjD,+DAA6C;AAC7C,gEAA8C;AAC9C,oEAAkD;AAClD,0DAAwC;AACxC,4DAA0C;AAC1C,mEAAiD;AACjD,wDAAsC;AACtC,0DAAwC;AACxC,2EAAyD;AACzD,iEAA+C;AAC/C,qEAAmD;AACnD,4EAA0D;AAC1D,8DAA4C;AAC5C,0EAAwD;AACxD,0DAAwC;AACxC,oEAAkD;AAClD,8DAA4C;AAC5C,wDAAsC;AACtC,6DAA2C;AAC3C,4DAA0C;AAC1C,sEAAoD;AACpD,qEAAmD;AACnD,0DAAwC;AACxC,kEAAgD;AAChD,yDAAuC;AACvC,mEAAiD;AACjD,2DAAyC;AACzC,oEAAkD;AAClD,6DAA2C;AAC3C,yDAAuC;AACvC,+DAA6C;AAC7C,wEAAsD;AACtD,+DAA6C;AAC7C,wDAAsC"}
@@ -0,0 +1,12 @@
1
+ import { LudeoEvent } from "../../infra/ludeo-event";
2
+ import { CloudSessionContext } from "../contexts";
3
+ export declare class MarkGameAvailablePayload {
4
+ gameResourceId: string;
5
+ gamePoolId: string;
6
+ }
7
+ export declare class MarkGameAvailable extends LudeoEvent {
8
+ static readonly EVENT_NAME = "cloud-sessions.mark-game-available";
9
+ constructor(payload: MarkGameAvailablePayload, context: CloudSessionContext);
10
+ context: CloudSessionContext;
11
+ payload: MarkGameAvailablePayload;
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.MarkGameAvailable = exports.MarkGameAvailablePayload = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const validate_nested_type_decorator_1 = require("../../decorators/validate-nested-type.decorator");
15
+ const ludeo_event_1 = require("../../infra/ludeo-event");
16
+ const contexts_1 = require("../contexts");
17
+ class MarkGameAvailablePayload {
18
+ }
19
+ exports.MarkGameAvailablePayload = MarkGameAvailablePayload;
20
+ __decorate([
21
+ (0, class_validator_1.IsUUID)(),
22
+ __metadata("design:type", String)
23
+ ], MarkGameAvailablePayload.prototype, "gameResourceId", void 0);
24
+ __decorate([
25
+ (0, class_validator_1.IsUUID)(),
26
+ __metadata("design:type", String)
27
+ ], MarkGameAvailablePayload.prototype, "gamePoolId", void 0);
28
+ class MarkGameAvailable extends ludeo_event_1.LudeoEvent {
29
+ constructor(payload, context) {
30
+ super(MarkGameAvailable.EVENT_NAME);
31
+ this.payload = payload;
32
+ this.context = context;
33
+ }
34
+ }
35
+ exports.MarkGameAvailable = MarkGameAvailable;
36
+ MarkGameAvailable.EVENT_NAME = "cloud-sessions.mark-game-available";
37
+ __decorate([
38
+ (0, validate_nested_type_decorator_1.ValidateNestedType)(() => contexts_1.CloudSessionContext),
39
+ __metadata("design:type", contexts_1.CloudSessionContext)
40
+ ], MarkGameAvailable.prototype, "context", void 0);
41
+ __decorate([
42
+ (0, validate_nested_type_decorator_1.ValidateNestedType)(() => MarkGameAvailablePayload),
43
+ __metadata("design:type", MarkGameAvailablePayload)
44
+ ], MarkGameAvailable.prototype, "payload", void 0);
45
+ //# sourceMappingURL=mark-game-available.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mark-game-available.js","sourceRoot":"","sources":["../../../src/v4/events/mark-game-available.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAyC;AAEzC,oGAAqF;AACrF,yDAAqD;AACrD,0CAAkD;AAElD,MAAa,wBAAwB;CAMpC;AAND,4DAMC;AAJC;IADC,IAAA,wBAAM,GAAE;;gEACc;AAGvB;IADC,IAAA,wBAAM,GAAE;;4DACU;AAGrB,MAAa,iBAAkB,SAAQ,wBAAU;IAG/C,YAAY,OAAiC,EAAE,OAA4B;QACzE,KAAK,CAAC,iBAAiB,CAAC,UAAU,CAAC,CAAC;QACpC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAPH,8CAcC;AAbiB,4BAAU,GAAG,oCAAoC,CAAC;AASlE;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,8BAAmB,CAAC;8BACrC,8BAAmB;kDAAC;AAG7B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,wBAAwB,CAAC;8BAC1C,wBAAwB;kDAAC"}
@@ -4,6 +4,7 @@ export declare class TerminateGameRequestPayload {
4
4
  gamePoolId: string;
5
5
  gameResourceId: string;
6
6
  uploadLogs?: boolean;
7
+ reason?: string;
7
8
  }
8
9
  export declare class TerminateGameRequest extends LudeoEvent {
9
10
  static readonly EVENT_NAME = "cloud-session-allocator.terminate-game-request";
@@ -30,6 +30,11 @@ __decorate([
30
30
  (0, class_validator_1.IsOptional)(),
31
31
  __metadata("design:type", Boolean)
32
32
  ], TerminateGameRequestPayload.prototype, "uploadLogs", void 0);
33
+ __decorate([
34
+ (0, class_validator_1.IsString)(),
35
+ (0, class_validator_1.IsOptional)(),
36
+ __metadata("design:type", String)
37
+ ], TerminateGameRequestPayload.prototype, "reason", void 0);
33
38
  class TerminateGameRequest extends ludeo_event_1.LudeoEvent {
34
39
  constructor(payload, context) {
35
40
  super(TerminateGameRequest.EVENT_NAME);
@@ -1 +1 @@
1
- {"version":3,"file":"terminate-game-request.js","sourceRoot":"","sources":["../../../src/v4/events/terminate-game-request.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAgE;AAEhE,0CAIqB;AACrB,yDAAqD;AACrD,oGAAqF;AAErF,MAAa,2BAA2B;CAUvC;AAVD,kEAUC;AARC;IADC,IAAA,wBAAM,GAAE;;+DACU;AAGnB;IADC,IAAA,wBAAM,GAAE;;mEACc;AAIvB;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,4BAAU,GAAE;;+DACQ;AAGvB,MAAa,oBAAqB,SAAQ,wBAAU;IAGlD,YACE,OAAoC,EACpC,OAAmD;QAEnD,KAAK,CAAC,oBAAoB,CAAC,UAAU,CAAC,CAAC;QACvC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,oDAiBC;AAhBiB,+BAAU,GAAG,gDAAgD,CAAC;AAY9E;IADC,IAAA,mDAAkB,EAAC,8BAAmB,CAAC;;qDACY;AAGpD;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,2BAA2B,CAAC;8BAC7C,2BAA2B;qDAAC"}
1
+ {"version":3,"file":"terminate-game-request.js","sourceRoot":"","sources":["../../../src/v4/events/terminate-game-request.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA0E;AAE1E,0CAIqB;AACrB,yDAAqD;AACrD,oGAAqF;AAErF,MAAa,2BAA2B;CAcvC;AAdD,kEAcC;AAZC;IADC,IAAA,wBAAM,GAAE;;+DACU;AAGnB;IADC,IAAA,wBAAM,GAAE;;mEACc;AAIvB;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,4BAAU,GAAE;;+DACQ;AAIrB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;2DACG;AAGlB,MAAa,oBAAqB,SAAQ,wBAAU;IAGlD,YACE,OAAoC,EACpC,OAAmD;QAEnD,KAAK,CAAC,oBAAoB,CAAC,UAAU,CAAC,CAAC;QACvC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,oDAiBC;AAhBiB,+BAAU,GAAG,gDAAgD,CAAC;AAY9E;IADC,IAAA,mDAAkB,EAAC,8BAAmB,CAAC;;qDACY;AAGpD;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,2BAA2B,CAAC;8BAC7C,2BAA2B;qDAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ludeo/cloud-common",
3
- "version": "1.2.27",
3
+ "version": "1.2.29",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "author": "Yahil Didi",
@@ -70,3 +70,4 @@ export * from "./game-resource-ready-for-creation";
70
70
  export * from "./game-resource-ready-for-creation-failed";
71
71
  export * from "./aws-stream-session-active";
72
72
  export * from "./cloud-session-optimal-region-selected";
73
+ export * from "./mark-game-available";
@@ -0,0 +1,29 @@
1
+ import { IsUUID } from "class-validator";
2
+
3
+ import { ValidateNestedType } from "../../decorators/validate-nested-type.decorator";
4
+ import { LudeoEvent } from "../../infra/ludeo-event";
5
+ import { CloudSessionContext } from "../contexts";
6
+
7
+ export class MarkGameAvailablePayload {
8
+ @IsUUID()
9
+ gameResourceId: string;
10
+
11
+ @IsUUID()
12
+ gamePoolId: string;
13
+ }
14
+
15
+ export class MarkGameAvailable extends LudeoEvent {
16
+ static readonly EVENT_NAME = "cloud-sessions.mark-game-available";
17
+
18
+ constructor(payload: MarkGameAvailablePayload, context: CloudSessionContext) {
19
+ super(MarkGameAvailable.EVENT_NAME);
20
+ this.payload = payload;
21
+ this.context = context;
22
+ }
23
+
24
+ @ValidateNestedType(() => CloudSessionContext)
25
+ context: CloudSessionContext;
26
+
27
+ @ValidateNestedType(() => MarkGameAvailablePayload)
28
+ payload: MarkGameAvailablePayload;
29
+ }
@@ -1,4 +1,4 @@
1
- import { IsBoolean, IsOptional, IsUUID } from "class-validator";
1
+ import { IsBoolean, IsOptional, IsString, IsUUID } from "class-validator";
2
2
 
3
3
  import {
4
4
  CloudResourceContext,
@@ -19,6 +19,10 @@ export class TerminateGameRequestPayload {
19
19
  @IsBoolean()
20
20
  @IsOptional()
21
21
  uploadLogs?: boolean;
22
+
23
+ @IsOptional()
24
+ @IsString()
25
+ reason?: string;
22
26
  }
23
27
 
24
28
  export class TerminateGameRequest extends LudeoEvent {
@@ -89,3 +89,4 @@ export * from "./ludeo-status-updated";
89
89
  export * from "./connection-id-timeout-task";
90
90
  export * from "./swap-to-default-user-request-failed";
91
91
  export * from "./cloud-session-stats-report";
92
+ export * from "./mark-game-available";
@@ -0,0 +1,29 @@
1
+ import { IsUUID } from "class-validator";
2
+
3
+ import { ValidateNestedType } from "../../decorators/validate-nested-type.decorator";
4
+ import { LudeoEvent } from "../../infra/ludeo-event";
5
+ import { CloudSessionContext } from "../contexts";
6
+
7
+ export class MarkGameAvailablePayload {
8
+ @IsUUID()
9
+ gameResourceId: string;
10
+
11
+ @IsUUID()
12
+ gamePoolId: string;
13
+ }
14
+
15
+ export class MarkGameAvailable extends LudeoEvent {
16
+ static readonly EVENT_NAME = "cloud-sessions.mark-game-available";
17
+
18
+ constructor(payload: MarkGameAvailablePayload, context: CloudSessionContext) {
19
+ super(MarkGameAvailable.EVENT_NAME);
20
+ this.payload = payload;
21
+ this.context = context;
22
+ }
23
+
24
+ @ValidateNestedType(() => CloudSessionContext)
25
+ context: CloudSessionContext;
26
+
27
+ @ValidateNestedType(() => MarkGameAvailablePayload)
28
+ payload: MarkGameAvailablePayload;
29
+ }
@@ -1,4 +1,4 @@
1
- import { IsBoolean, IsOptional, IsUUID } from "class-validator";
1
+ import { IsBoolean, IsOptional, IsString, IsUUID } from "class-validator";
2
2
 
3
3
  import {
4
4
  CloudResourceContext,
@@ -18,6 +18,10 @@ export class TerminateGameRequestPayload {
18
18
  @IsBoolean()
19
19
  @IsOptional()
20
20
  uploadLogs?: boolean;
21
+
22
+ @IsString()
23
+ @IsOptional()
24
+ reason?: string;
21
25
  }
22
26
 
23
27
  export class TerminateGameRequest extends LudeoEvent {