@ludeo/cloud-common 1.2.210 → 1.2.211

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 (38) hide show
  1. package/dist/tsconfig.tsbuildinfo +1 -1
  2. package/dist/v4/contexts/index.d.ts +1 -0
  3. package/dist/v4/contexts/index.js +1 -0
  4. package/dist/v4/contexts/index.js.map +1 -1
  5. package/dist/v4/contexts/provisioner-context.d.ts +4 -0
  6. package/dist/v4/contexts/provisioner-context.js +27 -0
  7. package/dist/v4/contexts/provisioner-context.js.map +1 -0
  8. package/dist/v4/events/forecast/forecast-ended.d.ts +1 -10
  9. package/dist/v4/events/forecast/forecast-ended.js +4 -22
  10. package/dist/v4/events/forecast/forecast-ended.js.map +1 -1
  11. package/dist/v4/events/index.d.ts +1 -0
  12. package/dist/v4/events/index.js +2 -1
  13. package/dist/v4/events/index.js.map +1 -1
  14. package/dist/v4/events/provisioner/index.d.ts +1 -0
  15. package/dist/v4/events/provisioner/index.js +18 -0
  16. package/dist/v4/events/provisioner/index.js.map +1 -0
  17. package/dist/v4/events/provisioner/provisioning-ended.d.ts +27 -0
  18. package/dist/v4/events/provisioner/provisioning-ended.js +77 -0
  19. package/dist/v4/events/provisioner/provisioning-ended.js.map +1 -0
  20. package/dist/v4/types/index.d.ts +1 -0
  21. package/dist/v4/types/index.js +1 -0
  22. package/dist/v4/types/index.js.map +1 -1
  23. package/dist/v4/types/predictor/index.d.ts +1 -0
  24. package/dist/v4/types/predictor/index.js +18 -0
  25. package/dist/v4/types/predictor/index.js.map +1 -0
  26. package/dist/v4/types/predictor/ludeo-features.d.ts +10 -0
  27. package/dist/v4/types/predictor/ludeo-features.js +34 -0
  28. package/dist/v4/types/predictor/ludeo-features.js.map +1 -0
  29. package/package.json +1 -1
  30. package/src/v4/contexts/index.ts +1 -0
  31. package/src/v4/contexts/provisioner-context.ts +11 -0
  32. package/src/v4/events/forecast/forecast-ended.ts +1 -18
  33. package/src/v4/events/index.ts +1 -0
  34. package/src/v4/events/provisioner/index.ts +1 -0
  35. package/src/v4/events/provisioner/provisioning-ended.ts +56 -0
  36. package/src/v4/types/index.ts +1 -0
  37. package/src/v4/types/predictor/index.ts +1 -0
  38. package/src/v4/types/predictor/ludeo-features.ts +20 -0
@@ -5,3 +5,4 @@ export * from "./getCloudContextType";
5
5
  export * from "./build-context";
6
6
  export * from "./client-geo-data";
7
7
  export * from "./forecast-context";
8
+ export * from "./provisioner-context";
@@ -21,4 +21,5 @@ __exportStar(require("./getCloudContextType"), exports);
21
21
  __exportStar(require("./build-context"), exports);
22
22
  __exportStar(require("./client-geo-data"), exports);
23
23
  __exportStar(require("./forecast-context"), exports);
24
+ __exportStar(require("./provisioner-context"), exports);
24
25
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v4/contexts/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC;AACrC,2DAAyC;AACzC,0DAAwC;AACxC,wDAAsC;AACtC,kDAAgC;AAChC,oDAAkC;AAClC,qDAAmC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v4/contexts/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC;AACrC,2DAAyC;AACzC,0DAAwC;AACxC,wDAAsC;AACtC,kDAAgC;AAChC,oDAAkC;AAClC,qDAAmC;AACnC,wDAAsC"}
@@ -0,0 +1,4 @@
1
+ export declare class ProvisionerContext {
2
+ provisioningRequestId?: string;
3
+ forecastRequestId?: string;
4
+ }
@@ -0,0 +1,27 @@
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.ProvisionerContext = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ class ProvisionerContext {
15
+ }
16
+ exports.ProvisionerContext = ProvisionerContext;
17
+ __decorate([
18
+ (0, class_validator_1.IsOptional)(),
19
+ (0, class_validator_1.IsUUID)(),
20
+ __metadata("design:type", String)
21
+ ], ProvisionerContext.prototype, "provisioningRequestId", void 0);
22
+ __decorate([
23
+ (0, class_validator_1.IsOptional)(),
24
+ (0, class_validator_1.IsUUID)(),
25
+ __metadata("design:type", String)
26
+ ], ProvisionerContext.prototype, "forecastRequestId", void 0);
27
+ //# sourceMappingURL=provisioner-context.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"provisioner-context.js","sourceRoot":"","sources":["../../../src/v4/contexts/provisioner-context.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAqD;AAErD,MAAa,kBAAkB;CAQ9B;AARD,gDAQC;AALC;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,wBAAM,GAAE;;iEACsB;AAI/B;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,wBAAM,GAAE;;6DACkB"}
@@ -1,15 +1,6 @@
1
1
  import { LudeoEvent } from "../../../infra";
2
2
  import { ForecastContext } from "../../contexts";
3
- export declare class ReservedLudeos {
4
- [ludeoId: string]: number;
5
- }
6
- export declare class LudeosPopularity {
7
- [ludeoId: string]: number;
8
- }
9
- export declare class LudeoFeatures {
10
- reservations?: ReservedLudeos;
11
- popularity?: LudeosPopularity;
12
- }
3
+ import { LudeoFeatures } from "../../types/predictor";
13
4
  export declare class ForecastMajorVersion {
14
5
  totalDemand: number;
15
6
  ludeoFeatures?: LudeoFeatures;
@@ -9,30 +9,12 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.ForecastEnded = exports.ForecastEndedPayload = exports.ForecastLocation = exports.ForecastEnvironment = exports.ForecastMajorVersion = exports.LudeoFeatures = exports.LudeosPopularity = exports.ReservedLudeos = void 0;
12
+ exports.ForecastEnded = exports.ForecastEndedPayload = exports.ForecastLocation = exports.ForecastEnvironment = exports.ForecastMajorVersion = void 0;
13
13
  const infra_1 = require("../../../infra");
14
14
  const decorators_1 = require("../../../decorators");
15
15
  const class_validator_1 = require("class-validator");
16
16
  const contexts_1 = require("../../contexts");
17
- class ReservedLudeos {
18
- }
19
- exports.ReservedLudeos = ReservedLudeos;
20
- class LudeosPopularity {
21
- }
22
- exports.LudeosPopularity = LudeosPopularity;
23
- class LudeoFeatures {
24
- }
25
- exports.LudeoFeatures = LudeoFeatures;
26
- __decorate([
27
- (0, class_validator_1.IsOptional)(),
28
- (0, decorators_1.ValidateNestedType)(() => ReservedLudeos),
29
- __metadata("design:type", ReservedLudeos)
30
- ], LudeoFeatures.prototype, "reservations", void 0);
31
- __decorate([
32
- (0, class_validator_1.IsOptional)(),
33
- (0, decorators_1.ValidateNestedType)(() => LudeosPopularity),
34
- __metadata("design:type", LudeosPopularity)
35
- ], LudeoFeatures.prototype, "popularity", void 0);
17
+ const predictor_1 = require("../../types/predictor");
36
18
  class ForecastMajorVersion {
37
19
  }
38
20
  exports.ForecastMajorVersion = ForecastMajorVersion;
@@ -42,8 +24,8 @@ __decorate([
42
24
  ], ForecastMajorVersion.prototype, "totalDemand", void 0);
43
25
  __decorate([
44
26
  (0, class_validator_1.IsOptional)(),
45
- (0, decorators_1.ValidateNestedType)(() => LudeoFeatures),
46
- __metadata("design:type", LudeoFeatures)
27
+ (0, decorators_1.ValidateNestedType)(() => predictor_1.LudeoFeatures),
28
+ __metadata("design:type", predictor_1.LudeoFeatures)
47
29
  ], ForecastMajorVersion.prototype, "ludeoFeatures", void 0);
48
30
  class ForecastEnvironment {
49
31
  }
@@ -1 +1 @@
1
- {"version":3,"file":"forecast-ended.js","sourceRoot":"","sources":["../../../../src/v4/events/forecast/forecast-ended.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,0CAA4C;AAC5C,oDAAyD;AACzD,qDAAkE;AAClE,6CAAiD;AAEjD,MAAa,cAAc;CAE1B;AAFD,wCAEC;AAED,MAAa,gBAAgB;CAE5B;AAFD,4CAEC;AAED,MAAa,aAAa;CAQzB;AARD,sCAQC;AALG;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,cAAc,CAAC;8BAC1B,cAAc;mDAAC;AAI9B;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,gBAAgB,CAAC;8BAC9B,gBAAgB;iDAAC;AAGlC,MAAa,oBAAoB;CAOhC;AAPD,oDAOC;AALG;IADC,IAAA,0BAAQ,GAAE;;yDACS;AAIpB;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,aAAa,CAAC;8BACxB,aAAa;2DAAC;AAGlC,MAAa,mBAAmB;CAE/B;AAFD,kDAEC;AAED,MAAa,gBAAgB;CAE5B;AAFD,4CAEC;AAED,MAAa,oBAAoB;CAMhC;AAND,oDAMC;AAHG;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,MAAM,CAAC;;uDAG/B;AAGN,MAAa,aAAc,SAAQ,kBAAU;IAGzC,YAAY,OAA6B,EAAE,OAAwB;QAC/D,KAAK,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;QAChC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC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AAkB,EAAC,GAAG,EAAE,CAAC,0BAAe,CAAC;8BACjC,0BAAe;8CAAC"}
@@ -178,5 +178,6 @@ export * as SiteController from "./site-controller";
178
178
  export * as CloudResources from "./cloud-resources";
179
179
  export * as CloudBuilds from "./cloud-builds";
180
180
  export * as Forecast from "./forecast";
181
+ export * as Provisioner from "./provisioner";
181
182
  export * as LudeocastAgent from "./ludeocast-agent";
182
183
  export * as SonicServer from "./sonic-server";
@@ -14,7 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- exports.SonicServer = exports.LudeocastAgent = exports.Forecast = exports.CloudBuilds = exports.CloudResources = exports.SiteController = void 0;
17
+ exports.SonicServer = exports.LudeocastAgent = exports.Provisioner = exports.Forecast = exports.CloudBuilds = exports.CloudResources = exports.SiteController = void 0;
18
18
  __exportStar(require("./allocate-game-request"), exports);
19
19
  __exportStar(require("./allocate-game-resource-request"), exports);
20
20
  __exportStar(require("./allocate-machine-request"), exports);
@@ -195,6 +195,7 @@ exports.SiteController = require("./site-controller");
195
195
  exports.CloudResources = require("./cloud-resources");
196
196
  exports.CloudBuilds = require("./cloud-builds");
197
197
  exports.Forecast = require("./forecast");
198
+ exports.Provisioner = require("./provisioner");
198
199
  exports.LudeocastAgent = require("./ludeocast-agent");
199
200
  exports.SonicServer = require("./sonic-server");
200
201
  //# 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;AACl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AEhE,sDAAoD;AACpD,sDAAoD;AACpD,gDAA8C;AAC9C,yCAAuC;AACvC,sDAAoD;AACpD,gDAA8C"}
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;AAC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AAC7D,uDAAqC;AACrC,4DAA0C;AAC1C,iDAA+B;AAC/B,kDAAgC;AAChC,4DAA0C;AAC1C,sEAAoD;AACpD,oEAAkD;AAClD,+DAA6C;AAC7C,gEAA8C;AAC9C,iEAA+C;AAC/C,2DAAyC;AACzC,mEAAiD;AACjD,iDAA+B;AAC/B,qDAAmC;AACnC,4DAA0C;AAC1C,8DAA4C;AAC5C,kDAAgC;AAChC,0DAAwC;AACxC,2DAAyC;AACzC,4DAA0C;AAC1C,oEAAkD;AAClD,2EAAyD;AACzD,kFAAgE;AAEhE,sDAAoD;AACpD,sDAAoD;AACpD,gDAA8C;AAC9C,yCAAuC;AACvC,+CAA6C;AAC7C,sDAAoD;AACpD,gDAA8C"}
@@ -0,0 +1 @@
1
+ export * from "./provisioning-ended";
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./provisioning-ended"), exports);
18
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/v4/events/provisioner/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC"}
@@ -0,0 +1,27 @@
1
+ import { LudeoEvent } from "../../../infra";
2
+ import { ProvisionerContext } from "../../contexts";
3
+ import { LudeoFeatures } from "../../types/predictor";
4
+ export declare class GamePool {
5
+ size: number;
6
+ ludeoFeatures?: LudeoFeatures;
7
+ }
8
+ export declare class Games {
9
+ [gamePoolId: string]: GamePool;
10
+ }
11
+ export declare class MachinePool {
12
+ size: number;
13
+ games: Games;
14
+ }
15
+ export declare class Machines {
16
+ [machinePoolId: string]: MachinePool;
17
+ }
18
+ export declare class ProvisioningEndedPayload {
19
+ machines: Machines;
20
+ gamePriorities: Record<string, number>;
21
+ }
22
+ export declare class ProvisioningEnded extends LudeoEvent {
23
+ static readonly EVENT_NAME = "provisioner.provisioning-ended";
24
+ constructor(payload: ProvisioningEndedPayload, context: ProvisionerContext);
25
+ payload: ProvisioningEndedPayload;
26
+ context: ProvisionerContext;
27
+ }
@@ -0,0 +1,77 @@
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.ProvisioningEnded = exports.ProvisioningEndedPayload = exports.Machines = exports.MachinePool = exports.Games = exports.GamePool = void 0;
13
+ const infra_1 = require("../../../infra");
14
+ const decorators_1 = require("../../../decorators");
15
+ const class_validator_1 = require("class-validator");
16
+ const contexts_1 = require("../../contexts");
17
+ const predictor_1 = require("../../types/predictor");
18
+ class GamePool {
19
+ }
20
+ exports.GamePool = GamePool;
21
+ __decorate([
22
+ (0, class_validator_1.IsNumber)(),
23
+ __metadata("design:type", Number)
24
+ ], GamePool.prototype, "size", void 0);
25
+ __decorate([
26
+ (0, class_validator_1.IsOptional)(),
27
+ (0, decorators_1.ValidateNestedType)(() => predictor_1.LudeoFeatures),
28
+ __metadata("design:type", predictor_1.LudeoFeatures)
29
+ ], GamePool.prototype, "ludeoFeatures", void 0);
30
+ class Games {
31
+ }
32
+ exports.Games = Games;
33
+ class MachinePool {
34
+ }
35
+ exports.MachinePool = MachinePool;
36
+ __decorate([
37
+ (0, class_validator_1.IsNumber)(),
38
+ __metadata("design:type", Number)
39
+ ], MachinePool.prototype, "size", void 0);
40
+ __decorate([
41
+ (0, class_validator_1.IsDefined)(),
42
+ (0, decorators_1.ValidateNestedType)(() => Games),
43
+ __metadata("design:type", Games)
44
+ ], MachinePool.prototype, "games", void 0);
45
+ class Machines {
46
+ }
47
+ exports.Machines = Machines;
48
+ class ProvisioningEndedPayload {
49
+ }
50
+ exports.ProvisioningEndedPayload = ProvisioningEndedPayload;
51
+ __decorate([
52
+ (0, class_validator_1.IsDefined)(),
53
+ (0, decorators_1.ValidateNestedType)(() => Object),
54
+ __metadata("design:type", Machines)
55
+ ], ProvisioningEndedPayload.prototype, "machines", void 0);
56
+ __decorate([
57
+ (0, class_validator_1.IsObject)(),
58
+ __metadata("design:type", Object)
59
+ ], ProvisioningEndedPayload.prototype, "gamePriorities", void 0);
60
+ class ProvisioningEnded extends infra_1.LudeoEvent {
61
+ constructor(payload, context) {
62
+ super(ProvisioningEnded.EVENT_NAME);
63
+ this.payload = payload;
64
+ this.context = context;
65
+ }
66
+ }
67
+ exports.ProvisioningEnded = ProvisioningEnded;
68
+ ProvisioningEnded.EVENT_NAME = "provisioner.provisioning-ended";
69
+ __decorate([
70
+ (0, decorators_1.ValidateNestedType)(() => ProvisioningEndedPayload),
71
+ __metadata("design:type", ProvisioningEndedPayload)
72
+ ], ProvisioningEnded.prototype, "payload", void 0);
73
+ __decorate([
74
+ (0, decorators_1.ValidateNestedType)(() => contexts_1.ProvisionerContext),
75
+ __metadata("design:type", contexts_1.ProvisionerContext)
76
+ ], ProvisioningEnded.prototype, "context", void 0);
77
+ //# sourceMappingURL=provisioning-ended.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"provisioning-ended.js","sourceRoot":"","sources":["../../../../src/v4/events/provisioner/provisioning-ended.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,0CAA4C;AAC5C,oDAAyD;AACzD,qDAA4E;AAC5E,6CAAoD;AACpD,qDAAsD;AAEtD,MAAa,QAAQ;CAOpB;AAPD,4BAOC;AALG;IADC,IAAA,0BAAQ,GAAE;;sCACE;AAIb;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,yBAAa,CAAC;8BACxB,yBAAa;+CAAC;AAGlC,MAAa,KAAK;CAEjB;AAFD,sBAEC;AAED,MAAa,WAAW;CAOvB;AAPD,kCAOC;AALG;IADC,IAAA,0BAAQ,GAAE;;yCACE;AAIb;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,KAAK,CAAC;8BACzB,KAAK;0CAAC;AAGjB,MAAa,QAAQ;CAEpB;AAFD,4BAEC;AAED,MAAa,wBAAwB;CAOpC;AAPD,4DAOC;AAJG;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,MAAM,CAAC;8BACvB,QAAQ;0DAAC;AAGnB;IADC,IAAA,0BAAQ,GAAE;;gEAC4B;AAG3C,MAAa,iBAAkB,SAAQ,kBAAU;IAG7C,YAAY,OAAiC,EAAE,OAA2B;QACtE,KAAK,CAAC,iBAAiB,CAAC,UAAU,CAAC,CAAC;QACpC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IAC3B,CAAC;;AAPL,8CAcC;AAbmB,4BAAU,GAAG,gCAAgC,CAAC;AAS9D;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,wBAAwB,CAAC;8BAC1C,wBAAwB;kDAAC;AAGlC;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,6BAAkB,CAAC;8BACpC,6BAAkB;kDAAC"}
@@ -2,3 +2,4 @@ export * from "./cloud";
2
2
  export * from "./pools";
3
3
  export * from "./build";
4
4
  export * from "./site-controller";
5
+ export * from "./predictor";
@@ -18,4 +18,5 @@ __exportStar(require("./cloud"), exports);
18
18
  __exportStar(require("./pools"), exports);
19
19
  __exportStar(require("./build"), exports);
20
20
  __exportStar(require("./site-controller"), exports);
21
+ __exportStar(require("./predictor"), exports);
21
22
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v4/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,0CAAwB;AACxB,0CAAwB;AACxB,oDAAkC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v4/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,0CAAwB;AACxB,0CAAwB;AACxB,oDAAkC;AAClC,8CAA4B"}
@@ -0,0 +1 @@
1
+ export * from "./ludeo-features";
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./ludeo-features"), exports);
18
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/v4/types/predictor/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC"}
@@ -0,0 +1,10 @@
1
+ export declare class ReservedLudeos {
2
+ [ludeoId: string]: number;
3
+ }
4
+ export declare class LudeosPopularity {
5
+ [ludeoId: string]: number;
6
+ }
7
+ export declare class LudeoFeatures {
8
+ reservations?: ReservedLudeos;
9
+ popularity?: LudeosPopularity;
10
+ }
@@ -0,0 +1,34 @@
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.LudeoFeatures = exports.LudeosPopularity = exports.ReservedLudeos = void 0;
13
+ const decorators_1 = require("../../../decorators");
14
+ const class_validator_1 = require("class-validator");
15
+ class ReservedLudeos {
16
+ }
17
+ exports.ReservedLudeos = ReservedLudeos;
18
+ class LudeosPopularity {
19
+ }
20
+ exports.LudeosPopularity = LudeosPopularity;
21
+ class LudeoFeatures {
22
+ }
23
+ exports.LudeoFeatures = LudeoFeatures;
24
+ __decorate([
25
+ (0, class_validator_1.IsOptional)(),
26
+ (0, decorators_1.ValidateNestedType)(() => ReservedLudeos),
27
+ __metadata("design:type", ReservedLudeos)
28
+ ], LudeoFeatures.prototype, "reservations", void 0);
29
+ __decorate([
30
+ (0, class_validator_1.IsOptional)(),
31
+ (0, decorators_1.ValidateNestedType)(() => LudeosPopularity),
32
+ __metadata("design:type", LudeosPopularity)
33
+ ], LudeoFeatures.prototype, "popularity", void 0);
34
+ //# sourceMappingURL=ludeo-features.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ludeo-features.js","sourceRoot":"","sources":["../../../../src/v4/types/predictor/ludeo-features.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAyD;AACzD,qDAA6C;AAE7C,MAAa,cAAc;CAE1B;AAFD,wCAEC;AAED,MAAa,gBAAgB;CAE5B;AAFD,4CAEC;AAED,MAAa,aAAa;CAQzB;AARD,sCAQC;AALG;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,cAAc,CAAC;8BAC1B,cAAc;mDAAC;AAI9B;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,gBAAgB,CAAC;8BAC9B,gBAAgB;iDAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ludeo/cloud-common",
3
- "version": "1.2.210",
3
+ "version": "1.2.211",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "author": "Yahil Didi",
@@ -5,3 +5,4 @@ export * from "./getCloudContextType";
5
5
  export * from "./build-context";
6
6
  export * from "./client-geo-data";
7
7
  export * from "./forecast-context";
8
+ export * from "./provisioner-context";
@@ -0,0 +1,11 @@
1
+ import { IsOptional, IsUUID } from "class-validator";
2
+
3
+ export class ProvisionerContext {
4
+ @IsOptional()
5
+ @IsUUID()
6
+ provisioningRequestId?: string;
7
+
8
+ @IsOptional()
9
+ @IsUUID()
10
+ forecastRequestId?: string;
11
+ }
@@ -2,24 +2,7 @@ import { LudeoEvent } from "../../../infra";
2
2
  import { ValidateNestedType } from "../../../decorators";
3
3
  import { IsDefined, IsNumber, IsOptional } from "class-validator";
4
4
  import { ForecastContext } from "../../contexts";
5
-
6
- export class ReservedLudeos {
7
- [ludeoId: string]: number;
8
- }
9
-
10
- export class LudeosPopularity {
11
- [ludeoId: string]: number;
12
- }
13
-
14
- export class LudeoFeatures {
15
- @IsOptional()
16
- @ValidateNestedType(() => ReservedLudeos)
17
- reservations?: ReservedLudeos;
18
-
19
- @IsOptional()
20
- @ValidateNestedType(() => LudeosPopularity)
21
- popularity?: LudeosPopularity;
22
- }
5
+ import { LudeoFeatures } from "../../types/predictor";
23
6
 
24
7
  export class ForecastMajorVersion {
25
8
  @IsNumber()
@@ -179,5 +179,6 @@ export * as SiteController from "./site-controller";
179
179
  export * as CloudResources from "./cloud-resources";
180
180
  export * as CloudBuilds from "./cloud-builds";
181
181
  export * as Forecast from "./forecast";
182
+ export * as Provisioner from "./provisioner";
182
183
  export * as LudeocastAgent from "./ludeocast-agent";
183
184
  export * as SonicServer from "./sonic-server";
@@ -0,0 +1 @@
1
+ export * from "./provisioning-ended";
@@ -0,0 +1,56 @@
1
+ import { LudeoEvent } from "../../../infra";
2
+ import { ValidateNestedType } from "../../../decorators";
3
+ import { IsDefined, IsNumber, IsObject, IsOptional } from "class-validator";
4
+ import { ProvisionerContext } from "../../contexts";
5
+ import { LudeoFeatures } from "../../types/predictor";
6
+
7
+ export class GamePool {
8
+ @IsNumber()
9
+ size: number;
10
+
11
+ @IsOptional()
12
+ @ValidateNestedType(() => LudeoFeatures)
13
+ ludeoFeatures?: LudeoFeatures;
14
+ }
15
+
16
+ export class Games {
17
+ [gamePoolId: string]: GamePool;
18
+ }
19
+
20
+ export class MachinePool {
21
+ @IsNumber()
22
+ size: number;
23
+
24
+ @IsDefined()
25
+ @ValidateNestedType(() => Games)
26
+ games: Games;
27
+ }
28
+
29
+ export class Machines {
30
+ [machinePoolId: string]: MachinePool;
31
+ }
32
+
33
+ export class ProvisioningEndedPayload {
34
+ @IsDefined()
35
+ @ValidateNestedType(() => Object)
36
+ machines: Machines;
37
+
38
+ @IsObject()
39
+ gamePriorities: Record<string, number>; // gameEnvironmentId -> priority
40
+ }
41
+
42
+ export class ProvisioningEnded extends LudeoEvent {
43
+ static readonly EVENT_NAME = "provisioner.provisioning-ended";
44
+
45
+ constructor(payload: ProvisioningEndedPayload, context: ProvisionerContext) {
46
+ super(ProvisioningEnded.EVENT_NAME);
47
+ this.payload = payload;
48
+ this.context = context;
49
+ }
50
+
51
+ @ValidateNestedType(() => ProvisioningEndedPayload)
52
+ payload: ProvisioningEndedPayload;
53
+
54
+ @ValidateNestedType(() => ProvisionerContext)
55
+ context: ProvisionerContext;
56
+ }
@@ -2,3 +2,4 @@ export * from "./cloud";
2
2
  export * from "./pools";
3
3
  export * from "./build";
4
4
  export * from "./site-controller";
5
+ export * from "./predictor";
@@ -0,0 +1 @@
1
+ export * from "./ludeo-features";
@@ -0,0 +1,20 @@
1
+ import { ValidateNestedType } from "../../../decorators";
2
+ import { IsOptional } from "class-validator";
3
+
4
+ export class ReservedLudeos {
5
+ [ludeoId: string]: number;
6
+ }
7
+
8
+ export class LudeosPopularity {
9
+ [ludeoId: string]: number;
10
+ }
11
+
12
+ export class LudeoFeatures {
13
+ @IsOptional()
14
+ @ValidateNestedType(() => ReservedLudeos)
15
+ reservations?: ReservedLudeos;
16
+
17
+ @IsOptional()
18
+ @ValidateNestedType(() => LudeosPopularity)
19
+ popularity?: LudeosPopularity;
20
+ }