fix(smartproxy): upgrade @push.rocks/smartproxy to ^23.1.0 and adapt code/tests for its async getStatistics() API

This commit is contained in:
2026-02-10 14:41:19 +00:00
parent 9d7da5bc25
commit e375adb80a
11 changed files with 196 additions and 94 deletions

View File

@@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@serve.zone/dcrouter',
version: '4.1.0',
version: '4.1.1',
description: 'A multifaceted routing service handling mail and SMS delivery functions.'
}

View File

@@ -123,8 +123,8 @@ export class MetricsManager {
return this.metricsCache.get('serverStats', async () => {
const smartMetricsData = await this.smartMetrics.getMetrics();
const proxyMetrics = this.dcRouter.smartProxy ? this.dcRouter.smartProxy.getMetrics() : null;
const proxyStats = this.dcRouter.smartProxy ? this.dcRouter.smartProxy.getStatistics() : null;
const proxyStats = this.dcRouter.smartProxy ? await this.dcRouter.smartProxy.getStatistics() : null;
return {
uptime: process.uptime(),
startTime: Date.now() - (process.uptime() * 1000),