feature request: logx should support log rotation based on log file size #1652
Closed as not planned
Description
Is your feature request related to a problem? Please describe.
At present, logx in go-zero's core support log rotation based on date. But it is not enough. In k8s,users can request and set limit on ephemeral-storage resource. But sometimes the admins of k8s might set the request maximum a little lower, to protect the node. So even if users try their best to reduce the log in their apps, and set the log rotation frequence on 1day, the pods of apps may still be evicted because of over the ephemeral-storage limit.
Therefore, logx should support log rotation based on log file size.
Describe the solution you'd like
The log file rotated when it is up to the size i set in logx config.
Describe alternatives you've considered
Additional context