Add migrated field to storage_operation_duration_seconds metric

This commit is contained in:
Jiawei Wang
2021-02-12 17:35:01 -08:00
parent ef319e24bc
commit 6a7222cf4e
12 changed files with 307 additions and 168 deletions

View File

@@ -23,7 +23,7 @@ import (
"regexp"
"testing"
"k8s.io/api/core/v1"
v1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/types"
@@ -121,9 +121,9 @@ func TestSyncHandler(t *testing.T) {
var expController *expandController
expController, _ = expc.(*expandController)
var expansionCalled bool
expController.operationGenerator = operationexecutor.NewFakeOGCounter(func() (error, error) {
expController.operationGenerator = operationexecutor.NewFakeOGCounter(func() volumetypes.OperationContext {
expansionCalled = true
return nil, nil
return volumetypes.NewOperationContext(nil, nil, false)
})
if test.pv != nil {