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

Method Write

modules/blockbuilder/writeable_block.go:46–54  ·  view source on GitHub ↗
(ctx context.Context, w backend.Writer)

Source from the content-addressed store, hash-verified

44func (b *WriteableBlock) BlockMeta() *backend.BlockMeta { return b.backendBlock.BlockMeta() }
45
46func (b *WriteableBlock) Write(ctx context.Context, w backend.Writer) error {
47 err := encoding.CopyBlock(ctx, b.BlockMeta(), b.reader, w)
48 if err != nil {
49 return fmt.Errorf("error copying block from local to remote backend: %w", err)
50 }
51
52 err = b.setFlushed(ctx)
53 return err
54}
55
56// TODO - Necessary?
57func (b *WriteableBlock) setFlushed(ctx context.Context) error {

Callers

nothing calls this directly

Implementers 1

WriteableBlockmodules/blockbuilder/writeable_block.g

Calls 3

BlockMetaMethod · 0.95
setFlushedMethod · 0.95
CopyBlockFunction · 0.92

Tested by

no test coverage detected