driskell / log-courier

The Log Courier Suite is a set of lightweight tools created to ship and process log files speedily and securely, with low resource usage, to Elasticsearch or Logstash instances.
Other
419 stars 107 forks source link

does the includes configuration still work correctly? #380

Closed wangzhuo0978 closed 3 years ago

wangzhuo0978 commented 3 years ago

The version I used before:

Log Courier version 2.0.5

way to start the program

log-courier -config=/etc/log-courier/log-courier.conf

the configuration summary is as follows:

{
  "general": {
    "log file": "/var/log/log-courier/log-courier.log",
    "persist directory": "/var/lib/log-courier"
  },
  "network": {
    "servers": ["xxx"],
    "transport": "tcp"
  },
  "includes": [ "/etc/log-courier/conf.d/*.conf" ]
} 

When create the sub configure files and place it when the path meets the conditions set by includes; it's ok; but I updated to the current version 2.5.6 It can still be started normally, but the configuration file contained in the includes path is not read;

driskell commented 3 years ago

You’re right - it’s loading them but not updating the runtime configuration with the new lists. Sorry about that. I’ll get to it shortly

driskell commented 3 years ago

Seeing that some issues have snuck in to the configuration - I resolved the include processing but then the validation has become read only and it's changes are not persisting so there's now new errors. I'll keep this open until that's resolved. I'm gradually adding more tests as the configuration parser is old and never had any (which didn't help in working on what was a feature and what wasn't) so hopefully will stop any further regressions.

So to confirm the 2.6.0 just released is in fact not working unfortunately 😢

driskell commented 3 years ago

Should now be resolved. I'll continue to get more tests around that code.