rust-tuf icon indicating copy to clipboard operation
rust-tuf copied to clipboard

Should we stop directly storing metadata MetadataVersion::None?

Open erickt opened this issue 7 years ago • 0 comments

As part #151, I started making rust-tuf concurrent. This means however that some previously safe patterns, like storing metadata both as MetadataVersion::Number(X) and MetadataVersion::None to signify it as the latest version is now racy since other threads can compete on updating metadata. What do you think about getting rid of MetadataVersion::None, and changing Repository::fetch_metadata to take a Option<MetadataVersion>, where None signifies getting the newest version?

erickt avatar Aug 01 '18 22:08 erickt