mirror of
https://github.com/grafana/grafana.git
synced 2024-11-26 02:40:26 -06:00
a31672fa40
* Rename RecordStatesAsync to Record * Rename QueryStates to Query * Implement fanout writes * Implement primary queries * Simplify error joining * Add test for query path * Add tests for writes and error propagation * Allow fanout backend to be configured * Touch up log messages and config validation * Consistent documentation for all backend structs * Parse and normalize backend names more consistently against an enum * Touch-ups to documentation * Improve clarity around multi-record blocking * Keep primary and secondaries more distinct * Rename fanout backend to multiple backend * Simplify config keys for multi backend mode
17 lines
567 B
Go
17 lines
567 B
Go
package historian
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/grafana/grafana-plugin-sdk-go/data"
|
|
|
|
"github.com/grafana/grafana/pkg/services/ngalert/models"
|
|
)
|
|
|
|
// Querier represents the ability to query state history.
|
|
// TODO: This package also contains implementations of this interface.
|
|
// TODO: This type should be moved to the side of the consumer, when the consumer is created in the future. We add it here temporarily to more clearly define this package's interface.
|
|
type Querier interface {
|
|
Query(ctx context.Context, query models.HistoryQuery) (*data.Frame, error)
|
|
}
|