MCPcopy
hub / github.com/grafana/tempo / Tombstone

Method Tombstone

tempodb/encoding/vparquet5/wal_block.go:547–557  ·  view source on GitHub ↗

Tombstone renames the block's meta.json to meta.deleted.json. Idempotent for already-tombstoned blocks (returns nil if meta.json is missing). See common.WALBlock.Tombstone for semantics.

()

Source from the content-addressed store, hash-verified

545// for already-tombstoned blocks (returns nil if meta.json is missing).
546// See common.WALBlock.Tombstone for semantics.
547func (b *walBlock) Tombstone() error {
548 from := filepath.Join(b.walPath(), backend.MetaName)
549 to := filepath.Join(b.walPath(), backend.DeletedMetaName)
550 if err := os.Rename(from, to); err != nil {
551 if os.IsNotExist(err) {
552 return nil
553 }
554 return fmt.Errorf("failed to tombstone wal block %s: %w", b.meta.BlockID, err)
555 }
556 return nil
557}
558
559func (b *walBlock) FindTraceByID(ctx context.Context, id common.ID, opts common.SearchOptions) (*tempopb.TraceByIDResponse, error) {
560 ctx, span := tracer.Start(ctx, "walBlock.FindTraceByID")

Callers

nothing calls this directly

Calls 2

walPathMethod · 0.95
JoinMethod · 0.65

Tested by

no test coverage detected