Using a fixed set of locks, then we don't need to free unused locks

anymore.
See kubernetes/kubernetes/pull/66442 for discussions.
This commit is contained in:
Yecheng Fu
2018-08-13 13:11:39 +08:00
parent a1b3133b46
commit 798838a6a0
11 changed files with 115 additions and 93 deletions

View File

@@ -50,7 +50,7 @@ var _ volume.VolumePlugin = &sioPlugin{}
func (p *sioPlugin) Init(host volume.VolumeHost) error {
p.host = host
p.volumeMtx = keymutex.NewKeyMutex()
p.volumeMtx = keymutex.NewHashed(0)
return nil
}