// Epoch returns the current mutation epoch of the volume. // // Returned value is valid after the transaction. func (v *Volume) Epoch() (clock.Epoch, error) { val := v.b.Get(volumeStateEpoch) var epoch clock.Epoch if err := epoch.UnmarshalBinary(val); err != nil { return 0, err } return epoch, nil }