27b52b1507
* ReplStore: Add support for multiple replicas and round-robin load balancing * add check for zero-length repls list
14 lines
340 B
Go
14 lines
340 B
Go
package db
|
|
|
|
import (
|
|
"github.com/grafana/grafana/pkg/services/sqlstore"
|
|
)
|
|
|
|
type ReplDB interface {
|
|
// DB is the primary database connection.
|
|
DB() *sqlstore.SQLStore
|
|
|
|
// ReadReplica is the read-only database connection. If no read replica is configured, the implementation must return the primary DB.
|
|
ReadReplica() *sqlstore.SQLStore
|
|
}
|