Documentation ¶
Overview ¶
Package indexer continously creates an index of the test results as the tiles, expectations and ignores change.
Index ¶
- Constants
- type Indexer
- type SearchIndex
- func (idx *SearchIndex) CalcSummaries(testNames []string, query url.Values, includeIgnores, head bool) (map[string]*summary.Summary, error)
- func (idx *SearchIndex) GetBlame(test, digest string, commits []*tiling.Commit) *blame.BlameDistribution
- func (idx *SearchIndex) GetIgnoreMatcher() paramtools.ParamMatcher
- func (idx *SearchIndex) GetParamsetSummary(test, digest string, includeIgnores bool) paramtools.ParamSet
- func (idx *SearchIndex) GetParamsetSummaryByTest(includeIgnores bool) map[string]map[string]paramtools.ParamSet
- func (idx *SearchIndex) GetSummaries(includeIgnores bool) map[string]*summary.Summary
- func (idx *SearchIndex) GetTile(includeIgnores bool) *tiling.Tile
- func (idx *SearchIndex) MaxDigestsByTest(includeIgnores bool) map[string]util.StringSet
- func (idx *SearchIndex) TalliesByQuery(query url.Values, includeIgnores bool) tally.Tally
- func (idx *SearchIndex) TalliesByTest(includeIgnores bool) map[string]tally.Tally
- func (idx *SearchIndex) TalliesByTrace(includeIgnores bool) map[string]tally.Tally
Constants ¶
const ( // Event emitted when the indexer updates the search index. // Callback argument: *SearchIndex EV_INDEX_UPDATED = "indexer:index-updated" // Metric to track the number of digests that do not have be uploaded by bots. METRIC_KNOWN_HASHES = "known-digests" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Indexer ¶
type Indexer struct {
// contains filtered or unexported fields
}
Indexer is the type that drive continously indexing as the underlying data change. It uses a DAG that encodes the dependencies of the different components of an index and creates a processing pipeline on top of it.
func New ¶
New returns a new Indexer instance. It synchronously indexes the initiallly available tile. If the indexing fails an error is returned. The provided interval defines how often the index should be refreshed.
func (*Indexer) GetIndex ¶
func (ixr *Indexer) GetIndex() *SearchIndex
GetIndex returns the current index, which is updated continously in the background. The returned instances of SearchIndex can be considered immutable and is not going to change. It should be used to handle an entire request to provide consistent information.
type SearchIndex ¶
type SearchIndex struct {
// contains filtered or unexported fields
}
SearchIndex contains everything that is necessary to search our current knowledge about test results. It should be considered as immutable. Whenever the underlying data change a new index is calculated via a pdag.
func (*SearchIndex) CalcSummaries ¶
func (idx *SearchIndex) CalcSummaries(testNames []string, query url.Values, includeIgnores, head bool) (map[string]*summary.Summary, error)
Proxy to summary.CalcSummaries.
func (*SearchIndex) GetBlame ¶
func (idx *SearchIndex) GetBlame(test, digest string, commits []*tiling.Commit) *blame.BlameDistribution
Proxy to blame.Blamer.GetBlame.
func (*SearchIndex) GetIgnoreMatcher ¶
func (idx *SearchIndex) GetIgnoreMatcher() paramtools.ParamMatcher
GetIgnoreMatcher returns a matcher for the ignore rules that were used to build the tile with ignores.
func (*SearchIndex) GetParamsetSummary ¶
func (idx *SearchIndex) GetParamsetSummary(test, digest string, includeIgnores bool) paramtools.ParamSet
Proxy to paramsets.Get
func (*SearchIndex) GetParamsetSummaryByTest ¶
func (idx *SearchIndex) GetParamsetSummaryByTest(includeIgnores bool) map[string]map[string]paramtools.ParamSet
Proxy to paramsets.GetByTest
func (*SearchIndex) GetSummaries ¶
func (idx *SearchIndex) GetSummaries(includeIgnores bool) map[string]*summary.Summary
Proxy to summary.Summary.Get.
func (*SearchIndex) GetTile ¶
func (idx *SearchIndex) GetTile(includeIgnores bool) *tiling.Tile
GetTile returns the current tile either with or without the ignored traces.
func (*SearchIndex) MaxDigestsByTest ¶
func (idx *SearchIndex) MaxDigestsByTest(includeIgnores bool) map[string]util.StringSet
Proxy to tally.Tallies.MaxDigestsByTest
func (*SearchIndex) TalliesByQuery ¶
ByQuery returns a Tally of all the digests that match the given query.
func (*SearchIndex) TalliesByTest ¶
func (idx *SearchIndex) TalliesByTest(includeIgnores bool) map[string]tally.Tally
Proxy to tally.Tallies.ByTest
func (*SearchIndex) TalliesByTrace ¶
func (idx *SearchIndex) TalliesByTrace(includeIgnores bool) map[string]tally.Tally
Proxy to tally.Tallies.ByTrace