You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
block/compact: rework consistency check, make writers only write
- It's weird that on upload errors, we try to clean everything and only
then write again. It's an extra operation we don't need since whether
a block exists or not hinges on the existence of meta.json. We don't
need to delete old, same files before trying to upload them again.
- Consequently, we need to always use the _upload_ time, not block
creation time when checking for consistency or when deleting partially
uploaded blocks. Directories as such don't exist in object storages,
it's a client-side "illusion", so we need to iterate through the
partial block's directory to fetch the last modified date.
Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
returntimestamp.Time(int64(blockID.Time())), fmt.Errorf("no last modified time found for block %s, using block creation time instead", blockID.String())
level.Warn(logger).Log("msg", "failed to delete aborted partial upload; will retry in next iteration", "block", id, "thresholdAge", PartialUploadThresholdAge, "err", err)
0 commit comments