Skip to content

Commit

Permalink
Review feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
njvrzm committed May 24, 2024
1 parent 5b01b3a commit 7ecffbc
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/athena/datasource.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ type AthenaDatasourceIface interface {
Columns(ctx context.Context, options sqlds.Options) ([]string, error)
}

// Loader fulfills the datasource.Loader interface from grafana-aws-sdk. This
// replaces the former approach of passing around functions.
type Loader struct{}

func (l Loader) LoadSettings(ctx context.Context) sqlModels.Settings {
Expand All @@ -55,6 +57,7 @@ func (l Loader) LoadAPI(ctx context.Context, cache *awsds.SessionCache, settings
}

func (l Loader) LoadDriver(ctx context.Context, awsapi sqlAPI.AWSAPI) (awsDriver.Driver, error) {
// The async driver serves both functions
return driver.New(ctx, awsapi)
}

Expand Down

0 comments on commit 7ecffbc

Please sign in to comment.