@ludeo/cloud-common 1.2.46 → 1.2.48
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/v4/events/index.d.ts +1 -1
- package/dist/v4/events/index.js +1 -1
- package/dist/v4/events/index.js.map +1 -1
- package/dist/v4/events/ludeo-resource-status-changed.d.ts +21 -0
- package/dist/v4/events/ludeo-resource-status-changed.js +79 -0
- package/dist/v4/events/ludeo-resource-status-changed.js.map +1 -0
- package/package.json +1 -1
- package/src/v4/events/index.ts +1 -1
- package/src/v4/events/ludeo-resource-status-changed.ts +63 -0
- package/dist/v4/events/ludeo-status-updated.d.ts +0 -14
- package/dist/v4/events/ludeo-status-updated.js +0 -50
- package/dist/v4/events/ludeo-status-updated.js.map +0 -1
- package/src/v4/events/ludeo-status-updated.ts +0 -35
|
@@ -85,7 +85,7 @@ export * from "./swap-to-default-user-completed";
|
|
|
85
85
|
export * from "./allocate-ludeo-request";
|
|
86
86
|
export * from "./allocate-ludeo-resource-request";
|
|
87
87
|
export * from "./terminate-ludeos-request";
|
|
88
|
-
export * from "./ludeo-status-
|
|
88
|
+
export * from "./ludeo-resource-status-changed";
|
|
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";
|
package/dist/v4/events/index.js
CHANGED
|
@@ -101,7 +101,7 @@ __exportStar(require("./swap-to-default-user-completed"), exports);
|
|
|
101
101
|
__exportStar(require("./allocate-ludeo-request"), exports);
|
|
102
102
|
__exportStar(require("./allocate-ludeo-resource-request"), exports);
|
|
103
103
|
__exportStar(require("./terminate-ludeos-request"), exports);
|
|
104
|
-
__exportStar(require("./ludeo-status-
|
|
104
|
+
__exportStar(require("./ludeo-resource-status-changed"), 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);
|
|
@@ -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,
|
|
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,kEAAgD;AAChD,+DAA6C;AAC7C,wEAAsD;AACtD,+DAA6C;AAC7C,wDAAsC;AACtC,gEAA8C;AAC9C,oEAAkD;AAClD,qEAAmD;AACnD,4EAA0D;AAC1D,4DAA0C;AAC1C,oDAAkC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
2
|
+
import { CloudResourceContext } from "../contexts/cloud-resource-context";
|
|
3
|
+
import { CloudProvider, CloudProviderSettings, CloudResourceStatus, GameResourceSettings } from "../types";
|
|
4
|
+
export declare class LudeoResourceStatusChangedPayload {
|
|
5
|
+
ludeoResourceId: string;
|
|
6
|
+
ludeoPoolId: string;
|
|
7
|
+
status: CloudResourceStatus;
|
|
8
|
+
previousGameStatus?: CloudResourceStatus;
|
|
9
|
+
gameResourceId: string;
|
|
10
|
+
gamePoolId: string;
|
|
11
|
+
gameId: string;
|
|
12
|
+
cloudProvider: CloudProvider;
|
|
13
|
+
providerSettings: CloudProviderSettings;
|
|
14
|
+
gameResourceSettings: GameResourceSettings;
|
|
15
|
+
}
|
|
16
|
+
export declare class LudeoResourceStatusChanged extends LudeoEvent {
|
|
17
|
+
static readonly EVENT_NAME = "cloud-pools.ludeo-resource-status-changed";
|
|
18
|
+
constructor(payload: LudeoResourceStatusChangedPayload, context: CloudResourceContext);
|
|
19
|
+
context: CloudResourceContext;
|
|
20
|
+
payload: LudeoResourceStatusChangedPayload;
|
|
21
|
+
}
|
|
@@ -0,0 +1,79 @@
|
|
|
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.LudeoResourceStatusChanged = exports.LudeoResourceStatusChangedPayload = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
const ludeo_event_1 = require("../../infra/ludeo-event");
|
|
15
|
+
const cloud_resource_context_1 = require("../contexts/cloud-resource-context");
|
|
16
|
+
const types_1 = require("../types");
|
|
17
|
+
const validate_nested_type_decorator_1 = require("../../decorators/validate-nested-type.decorator");
|
|
18
|
+
class LudeoResourceStatusChangedPayload {
|
|
19
|
+
}
|
|
20
|
+
exports.LudeoResourceStatusChangedPayload = LudeoResourceStatusChangedPayload;
|
|
21
|
+
__decorate([
|
|
22
|
+
(0, class_validator_1.IsUUID)(),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], LudeoResourceStatusChangedPayload.prototype, "ludeoResourceId", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
(0, class_validator_1.IsUUID)(),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], LudeoResourceStatusChangedPayload.prototype, "ludeoPoolId", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, class_validator_1.IsString)(),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], LudeoResourceStatusChangedPayload.prototype, "status", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, class_validator_1.IsString)(),
|
|
35
|
+
(0, class_validator_1.IsOptional)(),
|
|
36
|
+
__metadata("design:type", String)
|
|
37
|
+
], LudeoResourceStatusChangedPayload.prototype, "previousGameStatus", void 0);
|
|
38
|
+
__decorate([
|
|
39
|
+
(0, class_validator_1.IsUUID)(),
|
|
40
|
+
__metadata("design:type", String)
|
|
41
|
+
], LudeoResourceStatusChangedPayload.prototype, "gameResourceId", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, class_validator_1.IsUUID)(),
|
|
44
|
+
__metadata("design:type", String)
|
|
45
|
+
], LudeoResourceStatusChangedPayload.prototype, "gamePoolId", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, class_validator_1.IsUUID)(),
|
|
48
|
+
__metadata("design:type", String)
|
|
49
|
+
], LudeoResourceStatusChangedPayload.prototype, "gameId", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
(0, class_validator_1.IsEnum)(types_1.CloudProvider),
|
|
52
|
+
__metadata("design:type", String)
|
|
53
|
+
], LudeoResourceStatusChangedPayload.prototype, "cloudProvider", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => types_1.AWSProviderSettings),
|
|
56
|
+
__metadata("design:type", Object)
|
|
57
|
+
], LudeoResourceStatusChangedPayload.prototype, "providerSettings", void 0);
|
|
58
|
+
__decorate([
|
|
59
|
+
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => types_1.GameResourceSettings),
|
|
60
|
+
__metadata("design:type", types_1.GameResourceSettings)
|
|
61
|
+
], LudeoResourceStatusChangedPayload.prototype, "gameResourceSettings", void 0);
|
|
62
|
+
class LudeoResourceStatusChanged extends ludeo_event_1.LudeoEvent {
|
|
63
|
+
constructor(payload, context) {
|
|
64
|
+
super(LudeoResourceStatusChanged.EVENT_NAME);
|
|
65
|
+
this.payload = payload;
|
|
66
|
+
this.context = context;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
exports.LudeoResourceStatusChanged = LudeoResourceStatusChanged;
|
|
70
|
+
LudeoResourceStatusChanged.EVENT_NAME = "cloud-pools.ludeo-resource-status-changed";
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => cloud_resource_context_1.CloudResourceContext),
|
|
73
|
+
__metadata("design:type", cloud_resource_context_1.CloudResourceContext)
|
|
74
|
+
], LudeoResourceStatusChanged.prototype, "context", void 0);
|
|
75
|
+
__decorate([
|
|
76
|
+
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => LudeoResourceStatusChangedPayload),
|
|
77
|
+
__metadata("design:type", LudeoResourceStatusChangedPayload)
|
|
78
|
+
], LudeoResourceStatusChanged.prototype, "payload", void 0);
|
|
79
|
+
//# sourceMappingURL=ludeo-resource-status-changed.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ludeo-resource-status-changed.js","sourceRoot":"","sources":["../../../src/v4/events/ludeo-resource-status-changed.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAuE;AACvE,yDAAqD;AACrD,+EAA0E;AAC1E,oCAMkB;AAClB,oGAAqF;AAErF,MAAa,iCAAiC;CA+B7C;AA/BD,8EA+BC;AA7BC;IADC,IAAA,wBAAM,GAAE;;0EACe;AAGxB;IADC,IAAA,wBAAM,GAAE;;sEACW;AAGpB;IADC,IAAA,0BAAQ,GAAE;;iEACiB;AAI5B;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;6EAC4B;AAGzC;IADC,IAAA,wBAAM,GAAE;;yEACc;AAGvB;IADC,IAAA,wBAAM,GAAE;;qEACU;AAGnB;IADC,IAAA,wBAAM,GAAE;;iEACM;AAGf;IADC,IAAA,wBAAM,EAAC,qBAAa,CAAC;;wEACO;AAG7B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,2BAAmB,CAAC;;2EACN;AAGxC;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,4BAAoB,CAAC;8BACzB,4BAAoB;+EAAC;AAG7C,MAAa,0BAA2B,SAAQ,wBAAU;IAGxD,YACE,OAA0C,EAC1C,OAA6B;QAE7B,KAAK,CAAC,0BAA0B,CAAC,UAAU,CAAC,CAAC;QAC7C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,gEAiBC;AAhBiB,qCAAU,GAAG,2CAA2C,CAAC;AAYzE;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,6CAAoB,CAAC;8BACtC,6CAAoB;2DAAC;AAG9B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,iCAAiC,CAAC;8BACnD,iCAAiC;2DAAC"}
|
package/package.json
CHANGED
package/src/v4/events/index.ts
CHANGED
|
@@ -85,7 +85,7 @@ export * from "./swap-to-default-user-completed";
|
|
|
85
85
|
export * from "./allocate-ludeo-request";
|
|
86
86
|
export * from "./allocate-ludeo-resource-request";
|
|
87
87
|
export * from "./terminate-ludeos-request";
|
|
88
|
-
export * from "./ludeo-status-
|
|
88
|
+
export * from "./ludeo-resource-status-changed";
|
|
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";
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { IsEnum, IsOptional, IsString, IsUUID } from "class-validator";
|
|
2
|
+
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
3
|
+
import { CloudResourceContext } from "../contexts/cloud-resource-context";
|
|
4
|
+
import {
|
|
5
|
+
AWSProviderSettings,
|
|
6
|
+
CloudProvider,
|
|
7
|
+
CloudProviderSettings,
|
|
8
|
+
CloudResourceStatus,
|
|
9
|
+
GameResourceSettings,
|
|
10
|
+
} from "../types";
|
|
11
|
+
import { ValidateNestedType } from "../../decorators/validate-nested-type.decorator";
|
|
12
|
+
|
|
13
|
+
export class LudeoResourceStatusChangedPayload {
|
|
14
|
+
@IsUUID()
|
|
15
|
+
ludeoResourceId: string;
|
|
16
|
+
|
|
17
|
+
@IsUUID()
|
|
18
|
+
ludeoPoolId: string;
|
|
19
|
+
|
|
20
|
+
@IsString()
|
|
21
|
+
status: CloudResourceStatus;
|
|
22
|
+
|
|
23
|
+
@IsString()
|
|
24
|
+
@IsOptional()
|
|
25
|
+
previousGameStatus?: CloudResourceStatus;
|
|
26
|
+
|
|
27
|
+
@IsUUID()
|
|
28
|
+
gameResourceId: string;
|
|
29
|
+
|
|
30
|
+
@IsUUID()
|
|
31
|
+
gamePoolId: string;
|
|
32
|
+
|
|
33
|
+
@IsUUID()
|
|
34
|
+
gameId: string;
|
|
35
|
+
|
|
36
|
+
@IsEnum(CloudProvider)
|
|
37
|
+
cloudProvider: CloudProvider;
|
|
38
|
+
|
|
39
|
+
@ValidateNestedType(() => AWSProviderSettings)
|
|
40
|
+
providerSettings: CloudProviderSettings;
|
|
41
|
+
|
|
42
|
+
@ValidateNestedType(() => GameResourceSettings)
|
|
43
|
+
gameResourceSettings: GameResourceSettings;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export class LudeoResourceStatusChanged extends LudeoEvent {
|
|
47
|
+
static readonly EVENT_NAME = "cloud-pools.ludeo-resource-status-changed";
|
|
48
|
+
|
|
49
|
+
constructor(
|
|
50
|
+
payload: LudeoResourceStatusChangedPayload,
|
|
51
|
+
context: CloudResourceContext
|
|
52
|
+
) {
|
|
53
|
+
super(LudeoResourceStatusChanged.EVENT_NAME);
|
|
54
|
+
this.payload = payload;
|
|
55
|
+
this.context = context;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
@ValidateNestedType(() => CloudResourceContext)
|
|
59
|
+
context: CloudResourceContext;
|
|
60
|
+
|
|
61
|
+
@ValidateNestedType(() => LudeoResourceStatusChangedPayload)
|
|
62
|
+
payload: LudeoResourceStatusChangedPayload;
|
|
63
|
+
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
2
|
-
import { CloudResourceContext } from "../contexts/cloud-resource-context";
|
|
3
|
-
import { CloudResourceStatus } from "../types";
|
|
4
|
-
export declare class LudeoStatusUpdatedPayload {
|
|
5
|
-
ludeoResourceId: string;
|
|
6
|
-
ludeoPoolId: string;
|
|
7
|
-
status: CloudResourceStatus;
|
|
8
|
-
}
|
|
9
|
-
export declare class LudeoStatusUpdatedEvent extends LudeoEvent {
|
|
10
|
-
static readonly EVENT_NAME = "cloud-pools.ludeo-status-updated";
|
|
11
|
-
constructor(payload: LudeoStatusUpdatedPayload, context: CloudResourceContext);
|
|
12
|
-
context: CloudResourceContext;
|
|
13
|
-
payload: LudeoStatusUpdatedPayload;
|
|
14
|
-
}
|
|
@@ -1,50 +0,0 @@
|
|
|
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.LudeoStatusUpdatedEvent = exports.LudeoStatusUpdatedPayload = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const ludeo_event_1 = require("../../infra/ludeo-event");
|
|
15
|
-
const cloud_resource_context_1 = require("../contexts/cloud-resource-context");
|
|
16
|
-
const types_1 = require("../types");
|
|
17
|
-
const validate_nested_type_decorator_1 = require("../../decorators/validate-nested-type.decorator");
|
|
18
|
-
class LudeoStatusUpdatedPayload {
|
|
19
|
-
}
|
|
20
|
-
exports.LudeoStatusUpdatedPayload = LudeoStatusUpdatedPayload;
|
|
21
|
-
__decorate([
|
|
22
|
-
(0, class_validator_1.IsUUID)(),
|
|
23
|
-
__metadata("design:type", String)
|
|
24
|
-
], LudeoStatusUpdatedPayload.prototype, "ludeoResourceId", void 0);
|
|
25
|
-
__decorate([
|
|
26
|
-
(0, class_validator_1.IsUUID)(),
|
|
27
|
-
__metadata("design:type", String)
|
|
28
|
-
], LudeoStatusUpdatedPayload.prototype, "ludeoPoolId", void 0);
|
|
29
|
-
__decorate([
|
|
30
|
-
(0, class_validator_1.IsString)(),
|
|
31
|
-
__metadata("design:type", String)
|
|
32
|
-
], LudeoStatusUpdatedPayload.prototype, "status", void 0);
|
|
33
|
-
class LudeoStatusUpdatedEvent extends ludeo_event_1.LudeoEvent {
|
|
34
|
-
constructor(payload, context) {
|
|
35
|
-
super(LudeoStatusUpdatedEvent.EVENT_NAME);
|
|
36
|
-
this.payload = payload;
|
|
37
|
-
this.context = context;
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
exports.LudeoStatusUpdatedEvent = LudeoStatusUpdatedEvent;
|
|
41
|
-
LudeoStatusUpdatedEvent.EVENT_NAME = "cloud-pools.ludeo-status-updated";
|
|
42
|
-
__decorate([
|
|
43
|
-
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => cloud_resource_context_1.CloudResourceContext),
|
|
44
|
-
__metadata("design:type", cloud_resource_context_1.CloudResourceContext)
|
|
45
|
-
], LudeoStatusUpdatedEvent.prototype, "context", void 0);
|
|
46
|
-
__decorate([
|
|
47
|
-
(0, validate_nested_type_decorator_1.ValidateNestedType)(() => LudeoStatusUpdatedPayload),
|
|
48
|
-
__metadata("design:type", LudeoStatusUpdatedPayload)
|
|
49
|
-
], LudeoStatusUpdatedEvent.prototype, "payload", void 0);
|
|
50
|
-
//# sourceMappingURL=ludeo-status-updated.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ludeo-status-updated.js","sourceRoot":"","sources":["../../../src/v4/events/ludeo-status-updated.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAmD;AACnD,yDAAqD;AACrD,+EAA0E;AAC1E,oCAA+C;AAC/C,oGAAqF;AAErF,MAAa,yBAAyB;CASrC;AATD,8DASC;AAPC;IADC,IAAA,wBAAM,GAAE;;kEACe;AAGxB;IADC,IAAA,wBAAM,GAAE;;8DACW;AAGpB;IADC,IAAA,0BAAQ,GAAE;;yDACiB;AAG9B,MAAa,uBAAwB,SAAQ,wBAAU;IAGrD,YACE,OAAkC,EAClC,OAA6B;QAE7B,KAAK,CAAC,uBAAuB,CAAC,UAAU,CAAC,CAAC;QAC1C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,0DAiBC;AAhBiB,kCAAU,GAAG,kCAAkC,CAAC;AAYhE;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,6CAAoB,CAAC;8BACtC,6CAAoB;wDAAC;AAG9B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,yBAAyB,CAAC;8BAC3C,yBAAyB;wDAAC"}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { IsString, IsUUID } from "class-validator";
|
|
2
|
-
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
3
|
-
import { CloudResourceContext } from "../contexts/cloud-resource-context";
|
|
4
|
-
import { CloudResourceStatus } from "../types";
|
|
5
|
-
import { ValidateNestedType } from "../../decorators/validate-nested-type.decorator";
|
|
6
|
-
|
|
7
|
-
export class LudeoStatusUpdatedPayload {
|
|
8
|
-
@IsUUID()
|
|
9
|
-
ludeoResourceId: string;
|
|
10
|
-
|
|
11
|
-
@IsUUID()
|
|
12
|
-
ludeoPoolId: string;
|
|
13
|
-
|
|
14
|
-
@IsString()
|
|
15
|
-
status: CloudResourceStatus;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export class LudeoStatusUpdatedEvent extends LudeoEvent {
|
|
19
|
-
static readonly EVENT_NAME = "cloud-pools.ludeo-status-updated";
|
|
20
|
-
|
|
21
|
-
constructor(
|
|
22
|
-
payload: LudeoStatusUpdatedPayload,
|
|
23
|
-
context: CloudResourceContext
|
|
24
|
-
) {
|
|
25
|
-
super(LudeoStatusUpdatedEvent.EVENT_NAME);
|
|
26
|
-
this.payload = payload;
|
|
27
|
-
this.context = context;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
@ValidateNestedType(() => CloudResourceContext)
|
|
31
|
-
context: CloudResourceContext;
|
|
32
|
-
|
|
33
|
-
@ValidateNestedType(() => LudeoStatusUpdatedPayload)
|
|
34
|
-
payload: LudeoStatusUpdatedPayload;
|
|
35
|
-
}
|