driver: add context to Features interface

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax
2023-05-26 11:29:46 +02:00
parent d196ac347e
commit 8c65e4fc1d
7 changed files with 11 additions and 15 deletions

View File

@ -87,9 +87,8 @@ func (d *Driver) Client(ctx context.Context) (*client.Client, error) {
return client.New(ctx, d.InitConfig.EndpointAddr, opts...)
}
func (d *Driver) Features() map[driver.Feature]bool {
func (d *Driver) Features(ctx context.Context) map[driver.Feature]bool {
var historyAPI bool
ctx := context.Background()
c, err := d.Client(ctx)
if err == nil {
historyAPI = driver.HistoryAPISupported(ctx, c)