changelog

This commit is contained in:
mathieuRA
2025-07-21 09:45:00 +02:00
parent ecd18b84cf
commit 79be74c368
3 changed files with 5 additions and 12 deletions

View File

@@ -71,7 +71,7 @@ export async function promiseWriteInStream<T>({
stream?: Writable
handleError?: boolean
}): Promise<T | PromiseWriteInStreamError> {
let data: T | { error: true }
let data: T | PromiseWriteInStreamError
if (isPromise(maybePromise)) {
try {
data = await maybePromise

View File

@@ -136,7 +136,7 @@ export class XoaService {
return result
},
{ ...this.#dashboardCacheOpts, expiresIn: 1 }
this.#dashboardCacheOpts
)
if (brResult?.value !== undefined) {
@@ -548,11 +548,7 @@ export class XoaService {
promiseWriteInStream({ maybePromise: this.#getNumberOfPools(), path: 'nPools', stream }),
promiseWriteInStream({ maybePromise: this.#getNumberOfHosts(), path: 'nHosts', stream }),
promiseWriteInStream({ maybePromise: this.#getHostsStatus(), path: 'hostsStatus', stream }),
promiseWriteInStream({
maybePromise: this.#getResourcesOverview(),
path: 'resourcesOverview',
stream,
}),
promiseWriteInStream({ maybePromise: this.#getResourcesOverview(), path: 'resourcesOverview', stream }),
promiseWriteInStream({ maybePromise: this.#getVmsStatus(), path: 'vmsStatus', stream }),
promiseWriteInStream({
maybePromise: this.#getStorageRepositoriesSizeInfo(),
@@ -561,11 +557,7 @@ export class XoaService {
handleError: true,
}),
promiseWriteInStream({ maybePromise: this.#getPoolsStatus(), path: 'poolsStatus', stream }),
promiseWriteInStream({
maybePromise: this.#getMissingPatchesInfo(),
path: 'missingPatches',
stream,
}),
promiseWriteInStream({ maybePromise: this.#getMissingPatchesInfo(), path: 'missingPatches', stream }),
promiseWriteInStream({
maybePromise: this.#getBackupRepositoriesSizeInfo(),
path: 'backupRepositories',

View File

@@ -35,6 +35,7 @@
- [Health] Fix labels and modals mentioning VMs instead of snapshots when deleting snapshots (PR [#8775](https://github.com/vatesfr/xen-orchestra/pull/8775))
- [REST API] Alarm time is now in milliseconds and body value is now in percentage (PR [#8802](https://github.com/vatesfr/xen-orchestra/pull/8802))
- [REST API/XOA/Dashboard] Fix some type issues. Some object may return `{error: true}` instead of `undefined` on error.`s3` and `other` object may be undefined (if no S3 or other backup repositories detected) (PR [#8806](https://github.com/vatesfr/xen-orchestra/pull/8806))
### Packages to release