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

Function newStoreWithLogger

modules/backendscheduler/backendscheduler_test.go:264–287  ·  view source on GitHub ↗
(ctx context.Context, t testing.TB, log log.Logger, tmpDir string)

Source from the content-addressed store, hash-verified

262}
263
264func newStoreWithLogger(ctx context.Context, t testing.TB, log log.Logger, tmpDir string) storage.Store {
265 s, err := storage.NewStore(storage.Config{
266 Trace: tempodb.Config{
267 Backend: backend.Local,
268 Local: &local.Config{
269 Path: tmpDir + "/traces",
270 },
271 Block: &common.BlockConfig{
272 BloomFP: 0.01,
273 BloomShardSizeBytes: 100_000,
274 Version: encoding.LatestEncoding().Version(),
275 },
276 WAL: &wal.Config{
277 Filepath: tmpDir + "/wal",
278 },
279 BlocklistPoll: 100 * time.Millisecond,
280 },
281 }, nil, log)
282 require.NoError(t, err)
283
284 s.EnablePolling(ctx, &ownsEverythingSharder{}, false)
285
286 return s
287}
288
289func TestProtoMarshaler(t *testing.T) {
290 _, err := proto.Marshal(&tempopb.JobDetail{

Callers 1

newStoreFunction · 0.70

Calls 4

NewStoreFunction · 0.92
LatestEncodingFunction · 0.92
VersionMethod · 0.65
EnablePollingMethod · 0.65

Tested by

no test coverage detected