@chisquare-tech/origine-ngx-apps-services 0.2.1 → 0.2.3
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chisquare-tech/origine-ngx-apps-services",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "Origine's Services module screens: managed Postgres, MySQL and Valkey — the list with quota, the create wizard, and the instance page (connection details, attachments, databases and users, backups and PITR, metrics, logs, settings).",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -56,7 +56,7 @@ interface Engine {
|
|
|
56
56
|
available: boolean;
|
|
57
57
|
tag?: string;
|
|
58
58
|
databases: boolean;
|
|
59
|
-
ha?: 'standby' | 'cluster' | '';
|
|
59
|
+
ha?: 'standby' | 'replica' | 'cluster' | '';
|
|
60
60
|
maxReplicas?: number;
|
|
61
61
|
dumps?: boolean;
|
|
62
62
|
console: 'sql' | 'keys' | 'streams' | 'queues';
|
|
@@ -177,6 +177,17 @@ interface Backup {
|
|
|
177
177
|
startedAt?: string;
|
|
178
178
|
stoppedAt?: string;
|
|
179
179
|
error?: string;
|
|
180
|
+
/** The backup's volume snapshots (RabbitMQ's queue data), one per node. */
|
|
181
|
+
volumes?: {
|
|
182
|
+
phase: string;
|
|
183
|
+
snapshots: number;
|
|
184
|
+
error?: string;
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
interface ManagementLink {
|
|
188
|
+
url: string;
|
|
189
|
+
mode: 'admin' | 'read';
|
|
190
|
+
expiresAt: string;
|
|
180
191
|
}
|
|
181
192
|
interface Attachment {
|
|
182
193
|
id: string;
|
|
@@ -252,6 +263,20 @@ interface Detail extends Summary {
|
|
|
252
263
|
vhosts: string[] | null;
|
|
253
264
|
dumps: Dump[];
|
|
254
265
|
declaredBy?: string;
|
|
266
|
+
/** Valkey with replicas: where Sentinel-aware clients find the primary. */
|
|
267
|
+
sentinel?: {
|
|
268
|
+
hosts: string[];
|
|
269
|
+
port: number;
|
|
270
|
+
master: string;
|
|
271
|
+
};
|
|
272
|
+
/** RabbitMQ: the cell's snapshot class for the queue data, or why there is none. */
|
|
273
|
+
volumeSnapshots?: {
|
|
274
|
+
class?: string;
|
|
275
|
+
message?: string;
|
|
276
|
+
};
|
|
277
|
+
/** RabbitMQ: what the caller's role opens of the management UI. */
|
|
278
|
+
management?: 'admin' | 'read' | '';
|
|
279
|
+
restoreVolumes?: boolean;
|
|
255
280
|
}
|
|
256
281
|
interface Revealed {
|
|
257
282
|
user: string;
|
|
@@ -362,10 +387,13 @@ declare class ServicesApi {
|
|
|
362
387
|
retire(project: string, id: string, rotation: string): Observable<unknown>;
|
|
363
388
|
backupNow(project: string, id: string): Observable<unknown>;
|
|
364
389
|
deleteBackup(project: string, id: string, name: string): Observable<unknown>;
|
|
390
|
+
/** A link to a RabbitMQ instance's management UI, for the caller only (read-only for Developers). */
|
|
391
|
+
management(project: string, id: string): Observable<ManagementLink>;
|
|
365
392
|
restore(project: string, id: string, body: {
|
|
366
393
|
pointInTime?: string;
|
|
367
394
|
backup?: string;
|
|
368
395
|
name?: string;
|
|
396
|
+
volumes?: boolean;
|
|
369
397
|
}): Observable<Detail>;
|
|
370
398
|
attach(project: string, id: string, body: {
|
|
371
399
|
app: string;
|
|
@@ -448,6 +476,10 @@ declare const DAYS: {
|
|
|
448
476
|
id: string;
|
|
449
477
|
label: string;
|
|
450
478
|
}[];
|
|
479
|
+
/** While the browser tab is hidden, the page's polls slow to once a minute (the cell is read for each). */
|
|
480
|
+
declare const HIDDEN_POLL_MS = 60000;
|
|
481
|
+
/** The delay before the next poll: `visibleMs` while the page is seen, once a minute while it is hidden. */
|
|
482
|
+
declare function pollDelay(visibleMs: number): number;
|
|
451
483
|
|
|
452
484
|
declare class ServicesListPage {
|
|
453
485
|
protected readonly host: ServicesHost;
|
|
@@ -543,6 +575,8 @@ type Dialog = {
|
|
|
543
575
|
name: string;
|
|
544
576
|
point: string;
|
|
545
577
|
backup: string;
|
|
578
|
+
volumes?: boolean;
|
|
579
|
+
hasVolumes?: boolean;
|
|
546
580
|
} | {
|
|
547
581
|
kind: 'rotate';
|
|
548
582
|
user: string;
|
|
@@ -669,6 +703,7 @@ declare class ServicePage {
|
|
|
669
703
|
name: string;
|
|
670
704
|
point: string;
|
|
671
705
|
backup: string;
|
|
706
|
+
volumes?: boolean;
|
|
672
707
|
}): void;
|
|
673
708
|
protected swap(d: Detail, from: string): void;
|
|
674
709
|
protected save(d: Detail, body: Parameters<ServicesApi['update']>[2], ok: string): void;
|
|
@@ -678,6 +713,9 @@ declare class ServicePage {
|
|
|
678
713
|
protected remove(d: Detail, finalBackup: boolean): void;
|
|
679
714
|
protected nodesPrice(d: Detail): string;
|
|
680
715
|
protected refresh(): void;
|
|
716
|
+
/** Opens the instance's management UI in a new tab: a link for this person that expires. */
|
|
717
|
+
protected openManagement(d: Detail): void;
|
|
718
|
+
protected snapshotLine(d: Detail): string;
|
|
681
719
|
protected snapshotName(d: Detail): string;
|
|
682
720
|
/** MySQL replicas come in pairs. */
|
|
683
721
|
protected step(d: Detail): number;
|
|
@@ -819,5 +857,5 @@ declare class ServiceDumpsCard {
|
|
|
819
857
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ServiceDumpsCard, "o-svc-dumps", never, { "d": { "alias": "d"; "required": true; "isSignal": true; }; "projectKey": { "alias": "projectKey"; "required": true; "isSignal": true; }; "dumps": { "alias": "dumps"; "required": false; "isSignal": true; }; }, { "done": "done"; "failed": "failed"; }, never, never, true, never>;
|
|
820
858
|
}
|
|
821
859
|
|
|
822
|
-
export { DAYS, ENGINE_COLOUR, LIFECYCLE, PRESETS, ServiceConsoleTab, ServiceDumpsCard, ServiceLogsTab, ServiceMetricsTab, ServicePage, ServicesApi, ServicesHost, ServicesListPage, ServicesNewPage, apiMessage, backupKind, backupsLine, bytes, fromLocalInput, hhmm, hhmmss, money, moving, num, pct, presetChip, ratio, shortDate, spark, sparkPath, stateChip, stateDot, toLocalInput, utcHour, when };
|
|
823
|
-
export type { Attachment, Backup, Catalog, Connection, CreateInput, Database, Detail, Dump, Engine, EngineVersion, Figure, Gauge, Inspection, LogKind, LogLine, Logs, Metrics, Param, Plan, PodView, QueryResult, Quota, Revealed, Rotation, ServiceList, ServicesApp, ServicesProject, State, Stream, Summary, UpdateInput, UserView };
|
|
860
|
+
export { DAYS, ENGINE_COLOUR, HIDDEN_POLL_MS, LIFECYCLE, PRESETS, ServiceConsoleTab, ServiceDumpsCard, ServiceLogsTab, ServiceMetricsTab, ServicePage, ServicesApi, ServicesHost, ServicesListPage, ServicesNewPage, apiMessage, backupKind, backupsLine, bytes, fromLocalInput, hhmm, hhmmss, money, moving, num, pct, pollDelay, presetChip, ratio, shortDate, spark, sparkPath, stateChip, stateDot, toLocalInput, utcHour, when };
|
|
861
|
+
export type { Attachment, Backup, Catalog, Connection, CreateInput, Database, Detail, Dump, Engine, EngineVersion, Figure, Gauge, Inspection, LogKind, LogLine, Logs, ManagementLink, Metrics, Param, Plan, PodView, QueryResult, Quota, Revealed, Rotation, ServiceList, ServicesApp, ServicesProject, State, Stream, Summary, UpdateInput, UserView };
|