Skip to content

Commit

Permalink
The _latest objects store the time at which a point was written, not …
Browse files Browse the repository at this point in the history
…the timestamp stored in the point
  • Loading branch information
olorin committed Feb 19, 2015
1 parent aebd7cc commit a57117e
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions lib/Vaultaire/RollOver.hs
Original file line number Diff line number Diff line change
Expand Up @@ -93,14 +93,15 @@ rollOver origin day_file latest_file buckets =
originLockOID :: Origin -> ByteString
originLockOID = simpleLatestOID

-- | Construct the ID of the Ceph object storing the timestamp of the
-- latest 'SimplePoint' written to an origin.
-- | Construct the ID of the Ceph object storing the time at which the
-- latest 'SimplePoint' was written to an origin (note that this is
-- the time at which the point was written, *not* the timestamp of the
-- point itself).
simpleLatestOID :: Origin -> ByteString
simpleLatestOID (Origin origin') =
"02_" <> origin' <> "_simple_latest"

-- | Construct the ID of the Ceph object storing the timestamp of the
-- latest 'ExtendedPoint' written to an origin.
-- | Analogous to 'simpleLatestOID' for extended points.
extendedLatestOID :: Origin -> ByteString
extendedLatestOID (Origin origin') =
"02_" <> origin' <> "_extended_latest"

0 comments on commit a57117e

Please sign in to comment.