Make logging more consistent

This commit is contained in:
Göran Sander
2025-12-14 11:11:45 +01:00
parent 735e3941ac
commit b2fec2fcef
4 changed files with 6 additions and 6 deletions

View File

@@ -82,7 +82,7 @@ export async function storeEventCountInfluxDBV3() {
await writeToInfluxV3WithRetry(
async () => await globals.influx.write(point.toLineProtocol(), database),
'Log event count'
'Log event counts'
);
globals.logger.debug(`EVENT COUNT INFLUXDB V3: Wrote log event data to InfluxDB v3`);
}
@@ -129,7 +129,7 @@ export async function storeEventCountInfluxDBV3() {
await writeToInfluxV3WithRetry(
async () => await globals.influx.write(point.toLineProtocol(), database),
'User event count'
'User event counts'
);
globals.logger.debug(`EVENT COUNT INFLUXDB V3: Wrote user event data to InfluxDB v3`);
}
@@ -242,7 +242,7 @@ export async function storeRejectedEventCountInfluxDBV3() {
for (const point of points) {
await writeToInfluxV3WithRetry(
async () => await globals.influx.write(point.toLineProtocol(), database),
'Rejected event count'
'Rejected event counts'
);
}
globals.logger.debug(`REJECT LOG EVENT INFLUXDB V3: Wrote data to InfluxDB v3`);

View File

@@ -196,7 +196,7 @@ export async function postHealthMetricsToInfluxdbV3(serverName, host, body, serv
applyTagsToPoint3(point, serverTags);
await writeToInfluxV3WithRetry(
async () => await globals.influx.write(point.toLineProtocol(), database),
'Health metrics'
`Health metrics for ${host}`
);
}
globals.logger.debug(`HEALTH METRICS V3: Wrote data to InfluxDB v3`);

View File

@@ -197,7 +197,7 @@ export async function postLogEventToInfluxdbV3(msg) {
await writeToInfluxV3WithRetry(
async () => await globals.influx.write(point.toLineProtocol(), database),
'Log event'
`Log event for ${msg.host}`
);
globals.logger.debug(`LOG EVENT INFLUXDB V3: Wrote data to InfluxDB v3`);

View File

@@ -102,7 +102,7 @@ export async function postUserEventToInfluxdbV3(msg) {
// Convert point to line protocol and write directly with retry logic
await writeToInfluxV3WithRetry(
async () => await globals.influx.write(point.toLineProtocol(), database),
'User event'
`User event for ${msg.host}`
);
globals.logger.debug(`USER EVENT INFLUXDB V3: Wrote data to InfluxDB v3`);
} catch (err) {