MCPcopy Create free account
hub / github.com/cortexproject/cortex / MarkWithStatus

Method MarkWithStatus

pkg/compactor/visit_marker.go:102–109  ·  view source on GitHub ↗
(ctx context.Context, status VisitStatus)

Source from the content-addressed store, hash-verified

100}
101
102func (v *VisitMarkerManager) MarkWithStatus(ctx context.Context, status VisitStatus) {
103 v.visitMarker.UpdateStatus(v.ownerIdentifier, status)
104 if err := v.updateVisitMarker(ctx); err != nil {
105 level.Error(v.getLogger()).Log("msg", "unable to upsert visit marker file content", "new_status", status, "err", err)
106 return
107 }
108 level.Debug(v.getLogger()).Log("msg", "marked with new status", "new_status", status)
109}
110
111func (v *VisitMarkerManager) DeleteVisitMarker(ctx context.Context) {
112 if err := v.bkt.Delete(ctx, v.visitMarker.GetVisitMarkerFilePath()); err != nil {

Callers 7

TestMarkPendingFunction · 0.95
TestMarkInProgressFunction · 0.95
TestMarkCompletedFunction · 0.95
handleEmptyPartitionMethod · 0.95
HeartBeatMethod · 0.95

Calls 5

updateVisitMarkerMethod · 0.95
getLoggerMethod · 0.95
UpdateStatusMethod · 0.65
LogMethod · 0.45
ErrorMethod · 0.45

Tested by 4

TestMarkPendingFunction · 0.76
TestMarkInProgressFunction · 0.76
TestMarkCompletedFunction · 0.76