Azure-Samples / iotedge-logging-and-monitoring-solution

IoT Edge Logging and Monitoring Solution (ELMS) is an architecture and sample cloud workflow that enables automated retrieval of logs and metrics from IoT Edge devices
MIT License
42 stars 22 forks source link

Allow configuration of the log pulling interval #13

Open MagdaPaj opened 2 years ago

MagdaPaj commented 2 years ago

This issue is for a: (mark with an x)

- [ ] bug report -> please search issues before submitting
- [x] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

Pulling logs is partially configurable. There is a parameter LogsSince, that can be configured in the Function App settings, but the ScheduleUploadModuleLogs function has a timer trigger, every 15min, and this value is hardcoded. So, if someone changes LogsSince, but will not update the ScheduleUploadModuleLogs timer trigger, then it will result in logs gaps or logs duplication. It is a bit dangerous to have this value hardcoded.

Expected/desired behavior

Allow to configure ScheduleUploadModuleLogs timer trigger (for example during the deployment, or through the Function App setting, if possible).

Mention any other details that might be useful

It would be good to make sure that the same value for LogsSince and the timer trigger for the ScheduleUploadModuleLogs function is used (if I understand correctly, then there won't be any log gaps or duplication).