Description
Hey, @jongpie we discussed cases where we use the logger and came up with a similar idea. Potentially we will create a lot of logs per day and in most cases, they aren't really relevant to be stored for always. We looked into your Batch Deletion feature. But as far as we understand the feature does delete all logs after x days regardless of whether there is only info, an error, or in which context the log was created. What are your thoughts on setting up multiple retention rules depending on the scenario and included error?
For example:
- We have feature A which is very important. Logs of this feature must not be deleted at all.
- For Feature B we want to see the logs for 5 days. Then they can be deleted. Except there was an error. Then they should be deleted after 30 days.
- Feature C isn't really important. Logs should be deleted after 3 days.
All of the features have an identifier using the scenario field. And then there could be a custom metadata type where you can define a scenario, a retention day, and whether error logs should be skipped. For all logs without any scenario, you can have a default setting.
We probably will develop such a feature, but wanted to discuss it with you before. Maybe you say, that it might be relevant in general, then we can find some synergies.
Originally posted by @fentes in #207 (comment)