Skip to content

Commit

Permalink
Added info log messages where forcast information will be stored
Browse files Browse the repository at this point in the history
  • Loading branch information
klein0r committed Jul 3, 2022
1 parent 33317ed commit 5737c16
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,18 @@ class Pvforecast extends utils.Adapter {
if (!plant.peakpower || isNaN(plant.peakpower) || plant.peakpower < 0) {
throw new Error(`Invalid device configuration: Found plant without peak power`);
}

if (this.config.influxinstace) {
const cleanPlantId = this.cleanNamespace(plant.name);

this.log.info(`InfluxDB logging is enabled - forecast for plant "${plant.name}" will be available @ "${this.namespace}.plants.${cleanPlantId}.power"`);
}
});

if (this.config.influxinstace) {
this.log.info(`InfluxDB logging is enabled - forecast summary will be available @ "${this.namespace}.summary.power"`);
}

// Get list of valid plants by configuration
const plantsKeep = plantArray.map(d => `${this.namespace}.plants.${this.cleanNamespace(d.name)}`);

Expand Down

0 comments on commit 5737c16

Please sign in to comment.