MCPcopy Index your code
hub / github.com/cortexproject/cortex / createDeletionMark

Function createDeletionMark

pkg/compactor/compactor_test.go:1435–1441  ·  view source on GitHub ↗
(t *testing.T, bkt objstore.Bucket, userID string, blockID ulid.ULID, deletionTime time.Time)

Source from the content-addressed store, hash-verified

1433}
1434
1435func createDeletionMark(t *testing.T, bkt objstore.Bucket, userID string, blockID ulid.ULID, deletionTime time.Time) {
1436 content := mockDeletionMarkJSON(blockID.String(), deletionTime)
1437 blockPath := path.Join(userID, blockID.String())
1438 markPath := path.Join(blockPath, metadata.DeletionMarkFilename)
1439
1440 require.NoError(t, bkt.Upload(context.Background(), markPath, strings.NewReader(content)))
1441}
1442
1443func createNoCompactionMark(t *testing.T, bkt objstore.Bucket, userID string, blockID ulid.ULID) {
1444 content := mockNoCompactBlockJSON(blockID.String())

Calls 4

mockDeletionMarkJSONFunction · 0.85
JoinMethod · 0.80
StringMethod · 0.65
UploadMethod · 0.45

Tested by

no test coverage detected