Current Repository implementation checks for duplicated CommitId using an hashset on the loaded commits, so CommitId is guaranteed to be unique only for the commits loaded after a snapshot.
Most of the time this is not an issue, unless you have a very aggressive snapshot policy.
Should we move this check on the persistence level with an unique constraint?
Should be an optional check?
Current Repository implementation checks for duplicated CommitId using an hashset on the loaded commits, so CommitId is guaranteed to be unique only for the commits loaded after a snapshot.
Most of the time this is not an issue, unless you have a very aggressive snapshot policy.
Should we move this check on the persistence level with an unique constraint?
Should be an optional check?