blob: a5ece28a7afaf0a28ab8f29f0478a15251665768 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.vespa.streamingvisitors.tracing;
/**
* A sampling strategy makes the high-level decision of whether or not a query
* should be traced.
*
* Callers should be able to expect that calling shouldSample() is a cheap operation
* with little or no underlying locking. This in turn means that the sampling strategy
* may be consulted for each query with minimal overhead.
*/
public interface SamplingStrategy {
boolean shouldSample();
}
|