Remove unused waitSleepTime field in csiAttacher

This commit is contained in:
Chris Henzie 2020-12-28 11:52:32 -08:00
parent 81b13a912c
commit b4e3f272b9
3 changed files with 4 additions and 7 deletions

View File

@ -46,9 +46,8 @@ const (
) )
type csiAttacher struct { type csiAttacher struct {
plugin *csiPlugin plugin *csiPlugin
k8s kubernetes.Interface k8s kubernetes.Interface
waitSleepTime time.Duration
csiClient csiClient csiClient csiClient
} }

View File

@ -990,7 +990,6 @@ func TestAttacherDetach(t *testing.T) {
t.Errorf("test case %s failed: %v", tc.name, err) t.Errorf("test case %s failed: %v", tc.name, err)
} }
watchError := tc.watcherError watchError := tc.watcherError
csiAttacher.waitSleepTime = 100 * time.Millisecond
go func() { go func() {
if watchError { if watchError {
errStatus := apierrors.NewInternalError(fmt.Errorf("we got an error")).Status() errStatus := apierrors.NewInternalError(fmt.Errorf("we got an error")).Status()

View File

@ -944,9 +944,8 @@ func (p *csiPlugin) newAttacherDetacher() (*csiAttacher, error) {
} }
return &csiAttacher{ return &csiAttacher{
plugin: p, plugin: p,
k8s: k8s, k8s: k8s,
waitSleepTime: 1 * time.Second,
}, nil }, nil
} }