mirror of
https://github.com/grafana/grafana.git
synced 2025-08-02 07:12:13 +08:00
Data sources: Use SQL store directly, not via bus (#27000)
* Server: Make it possible to avoid getting SQL store via bus Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com>
This commit is contained in:
@ -70,7 +70,7 @@ func (ss *SqlStore) Init() error {
|
||||
|
||||
engine, err := ss.getEngine()
|
||||
if err != nil {
|
||||
return fmt.Errorf("Fail to connect to database: %v", err)
|
||||
return errutil.Wrap("failed to connect to database", err)
|
||||
}
|
||||
|
||||
ss.engine = engine
|
||||
@ -91,7 +91,7 @@ func (ss *SqlStore) Init() error {
|
||||
}
|
||||
|
||||
if err := migrator.Start(); err != nil {
|
||||
return fmt.Errorf("Migration failed err: %v", err)
|
||||
return errutil.Wrap("migration failed", err)
|
||||
}
|
||||
|
||||
// Init repo instances
|
||||
|
Reference in New Issue
Block a user