clone data for demo/dev env

This commit is contained in:
2026-07-05 18:54:33 +05:00
parent 5b97022116
commit 3c94cd92c1
2 changed files with 16 additions and 1 deletions

View File

@@ -1,4 +1,4 @@
import { postCloudIngest } from '../cloud-ingest.js'
import { postCloudIngest, postDemoCloudIngest } from '../cloud-ingest.js'
import { log } from '../helpers/log.js'
import type { TopicHandler } from '../types.js'
@@ -97,6 +97,9 @@ async function postMetrics(metrics: Edge5ModbusV3Metric[]): Promise<void> {
const text = await response.text()
throw new Error(text || `${response.status} ${response.statusText}`)
}
void postDemoCloudIngest(metric); // для демо-системы
} catch (error) {
const message = error instanceof Error ? error.message : String(error)
errors.push(new Error(`${metric.tag}: ${message}`))