File tree Expand file tree Collapse file tree 8 files changed +8506
-4306
lines changed
github.com/container-storage-interface/spec/lib/go/csi Expand file tree Collapse file tree 8 files changed +8506
-4306
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ require (
77 github.com/Azure/go-autorest/autorest v0.11.29
88 github.com/Azure/go-autorest/autorest/adal v0.9.23
99 github.com/Azure/go-autorest/autorest/to v0.4.0
10- github.com/container-storage-interface/spec v1.8 .0
10+ github.com/container-storage-interface/spec v1.11 .0
1111 github.com/golang/protobuf v1.5.4
1212 github.com/kubernetes-csi/csi-lib-utils v0.13.0
1313 github.com/kubernetes-csi/csi-proxy/client v1.0.1
Original file line number Diff line number Diff line change @@ -55,8 +55,8 @@ github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMn
5555github.com/client9/misspell v0.3.4 /go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw =
5656github.com/cncf/xds/go v0.0.0-20240423153145-555b57ec207b h1:ga8SEFjZ60pxLcmhnThWgvH2wg8376yUJmPhEH4H3kw =
5757github.com/cncf/xds/go v0.0.0-20240423153145-555b57ec207b /go.mod h1:W+zGtBO5Y1IgJhy4+A9GOqVhqLpfZi+vwmdNXUehLA8 =
58- github.com/container-storage-interface/spec v1.8 .0 h1:D0vhF3PLIZwlwZEf2eNbpujGCNwspwTYf2idJRJx4xI =
59- github.com/container-storage-interface/spec v1.8 .0 /go.mod h1:ROLik+GhPslwwWRNFF1KasPzroNARibH2rfz1rkg4H0 =
58+ github.com/container-storage-interface/spec v1.11 .0 h1:H/YKTOeUZwHtyPOr9raR+HgFmGluGCklulxDYxSdVNM =
59+ github.com/container-storage-interface/spec v1.11 .0 /go.mod h1:DtUvaQszPml1YJfIK7c00mlv6/g4wNMLanLgiUbKFRI =
6060github.com/coreos/go-semver v0.3.1 h1:yi21YpKnrx1gt5R+la8n5WgS0kCrsPp33dmEyHReZr4 =
6161github.com/coreos/go-semver v0.3.1 /go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03VsM8rvUec =
6262github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs =
Original file line number Diff line number Diff line change @@ -116,7 +116,6 @@ func TestLogGRPC(t *testing.T) {
116116 "account_name" : "k8s" ,
117117 "account_key" : "testkey" ,
118118 },
119- XXX_sizecache : 100 ,
120119 },
121120 `GRPC request: {"secrets":"***stripped***","volume_id":"vol_1"}` ,
122121 },
@@ -202,7 +201,6 @@ func TestNewControllerServiceCapability(t *testing.T) {
202201 for _ , test := range tests {
203202 resp := NewControllerServiceCapability (test .cap )
204203 assert .NotNil (t , resp )
205- assert .Equal (t , resp .XXX_sizecache , int32 (0 ))
206204 }
207205}
208206
@@ -226,7 +224,6 @@ func TestNewNodeServiceCapability(t *testing.T) {
226224 for _ , test := range tests {
227225 resp := NewNodeServiceCapability (test .cap )
228226 assert .NotNil (t , resp )
229- assert .Equal (t , resp .XXX_sizecache , int32 (0 ))
230227 }
231228}
232229
Original file line number Diff line number Diff line change @@ -68,7 +68,6 @@ func TestProbe(t *testing.T) {
6868 resp , err := d .Probe (context .Background (), & req )
6969 assert .NoError (t , err )
7070 assert .NotNil (t , resp )
71- assert .Equal (t , resp .XXX_sizecache , int32 (0 ))
7271 assert .Equal (t , resp .Ready .Value , true )
7372}
7473
@@ -87,6 +86,5 @@ func TestGetPluginCapabilities(t *testing.T) {
8786 resp , err := d .GetPluginCapabilities (context .Background (), & req )
8887 assert .NoError (t , err )
8988 assert .NotNil (t , resp )
90- assert .Equal (t , resp .XXX_sizecache , int32 (0 ))
9189 assert .Equal (t , resp .Capabilities , expectedCap )
9290}
Original file line number Diff line number Diff line change @@ -78,6 +78,12 @@ type DriverOptions struct {
7878// Driver implements all interfaces of CSI drivers
7979type Driver struct {
8080 csicommon.CSIDriver
81+ // Embed UnimplementedXXXServer to ensure the driver returns Unimplemented for any
82+ // new RPC methods that might be introduced in future versions of the spec.
83+ csi.UnimplementedControllerServer
84+ csi.UnimplementedIdentityServer
85+ csi.UnimplementedNodeServer
86+
8187 mounter * mount.SafeFormatAndMount
8288 // A map storing all volumes with ongoing operations so that additional operations
8389 // for that same volume (as defined by VolumeID) return an Aborted error
You can’t perform that action at this time.
0 commit comments