scan mirror before enabling after down/unreachable
I think it would be wise to scan a mirror that was "unreachable" before mirrorbits auto enables it.
For instance
Mirror goes down,
mirrorbits sees this and disables it.
While mirror is down, some directory's are removed.
mirror back up, mirrorbits blindly enables mirror assuming it has all the files it did when it went down.
users get a 404 for missing files.
Maybe there's a timer where it will do this automatically.
Keep up the good work : ]
The easiest way I see to avoid this edge case would be to check if the last successful mirror sync < ScanInterval then enable the mirror without prior checking (like it does now), else wait for a successful scan before re-enabling the mirror.
What do you think?
The problem that can arise is that if mirrorbits was stopped or the server looses its connectivity for quite some time (basically > ScanInterval), it will be unable to serve files at full capacity right away when the connectivity gets back because it needs to wait for a scan of all mirrors. But this new edge case can be mitigated with mirrorbits cluster as long as the other node is able to access and scan the mirrors.
I think there could be potential issues with a mirror being enabled out of sync.
Without a cluster, i can see the need for mirrorbits to enable everything upon connectivity being restored.
If a server is offline for X amount of time, i think MB should force a rescan before it enables. Especially if the server had some sort of an outage, it could be way out of sync. Kodi has some 22,000 + files.
If someone used MB for a repo like ubuntu there's a huge amount of files constantly changing.
I know a lot of mirrors are really slow to sync so it may cause a delay for those servers being enabled.
only a suggestion. : ]
Why closing it? It's definitely on my radar.