Documentation ¶
Index ¶
Constants ¶
View Source
const ( Upscale vmv1.Flag = 1 << iota Downscale )
View Source
const MaxRevisions = 100
MaxRevisions is the maximum number of revisions that can be stored in the RevisionSource. This is to prevent memory leaks. Upon reaching it, the oldest revisions are discarded.
Variables ¶
This section is empty.
Functions ¶
func Propagate ¶
func Propagate( now time.Time, target vmv1.RevisionWithTime, currentSlot *vmv1.Revision, cb ObserveCallback, )
Propagate sets the target revision to be current, optionally measuring the time it took for propagation.
Types ¶
type RevisionSource ¶
type RevisionSource struct {
// contains filtered or unexported fields
}
RevisionSource can generate and observe revisions. Each Revision is a value and a set of flags (for meta-information). Once RevisionSource observes a previously generated Revision after some time, the time it took since that Revision was generated.
func NewRevisionSource ¶
func NewRevisionSource(initialRevision int64, cb ObserveCallback) *RevisionSource
Click to show internal directories.
Click to hide internal directories.