Documentation ¶
Index ¶
- func NewControlRouter(cHandler *Handler) http.Handler
- type Backend
- type Handler
- func (ch *Handler) ForceLoad(c web.C, w http.ResponseWriter, r *http.Request)
- func (ch *Handler) IncrementVersion(c web.C, w http.ResponseWriter, r *http.Request)
- func (ch *Handler) LastLoad(c web.C, w http.ResponseWriter, r *http.Request)
- func (ch *Handler) TableExists(c web.C, w http.ResponseWriter, r *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewControlRouter ¶
NewControlRouter instantiates an http.Handler with the control routes
Types ¶
type Backend ¶
type Backend struct {
// contains filtered or unexported fields
}
Backend is the backend for control, which operates on the ingester
func NewControlBackend ¶
func NewControlBackend(metaReader metadata.Reader, metaBackend metadata.Backend, tableVersions versions.Getter, versionIncrement chan migrator.VersionIncrement) *Backend
NewControlBackend instantiates the control backend with a db connection
func (*Backend) IncrementVersion ¶
IncrementVersion increments the given table's version in the migrator goroutine.
func (*Backend) TableExists ¶
TableExists returns whether the given table name exists in our version dictionary.
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler is a handler for control
func NewControlHandler ¶
func NewControlHandler(ch *Backend, stats monitoring.SafeStatter) *Handler
NewControlHandler instantiates a handler for control
func (*Handler) ForceLoad ¶
ForceLoad forces ingest of a particular table. Takes a JSON POST containing the Table and Requester fields, representing the what to force load and who wants it.
func (*Handler) IncrementVersion ¶
IncrementVersion sets the table's version in infra.table_version to the given version.
func (*Handler) TableExists ¶
TableExists returns a boolean indicating whether the given table exists.