+1, I think you are right, we should not remove packs if the pack file exists but we can't access it due to another reason.
We could try to further differentiate the causes for FileNotFoundException, by e.g. analysing the error message.
Yes, we could in theory but we shouldn't for sake of future-proof compatibility IMHO.
We do know that the file exists already, because of the previous if condition.
We should also think about how to prevent flooding the logs if such an error condition doesn't go away so that we keep logging
the same problem over and over again.
I was thinking about that yesterday. We should have a maximum retry count logic.
This means that if JGit tried to open a pack file for N consecutive times without success and the pack file exists, it should then just give up and remove it from the list as it does today.
This parameter should be configurable with a "common sense" default value.
This could have the effect that a single pack facing such a problem might stall
a JGit based server by excessive logging. Maybe we should quarantine affected packs and retry reading them
later after an increasing delay.
Please sign the ECA here
and then push this change to Gerrit.
We are not allowed to accept patches from users who haven't signed their ECA
I did already, and if I try to do it now it just says that it is done.
However, I still cannot push to Gerrit :-(
How long does it take for the Eclipse guys to approve my ECA ?
Luca.