Currently the indexer logs only rotate (by default) one day after the indexer was last restarted. If the indexer is regularly restarted the logs will rarely get rotated. There should be a better way to check if the log needs rotating.
The best plan I can think of is to check the last modified time of indexer.log.1 and if this is over a day (or whatever the log rotation set is set to) then rotate the logs. Like the existing method, which is done as part of a respawn, this is checked each time the event queue is polled. The only problem is if there is not yet an indexer.log.1. Therefore, the best plan may be to create an empty file if it does not exist and then this will ensure a day later (or whatever the setting) the log file will be rotated.
Currently the indexer logs only rotate (by default) one day after the indexer was last restarted. If the indexer is regularly restarted the logs will rarely get rotated. There should be a better way to check if the log needs rotating.
The best plan I can think of is to check the last modified time of indexer.log.1 and if this is over a day (or whatever the log rotation set is set to) then rotate the logs. Like the existing method, which is done as part of a respawn, this is checked each time the event queue is polled. The only problem is if there is not yet an indexer.log.1. Therefore, the best plan may be to create an empty file if it does not exist and then this will ensure a day later (or whatever the setting) the log file will be rotated.