Skip to content

Commit 6504e5c

Browse files
committed
manila-csi-plugin: Unify some logging between cinder, manila
Signed-off-by: Stephen Finucane <[email protected]>
1 parent 9f181e6 commit 6504e5c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

pkg/csi/manila/identityserver.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,24 @@ import (
2222
"github.com/container-storage-interface/spec/lib/go/csi"
2323
"google.golang.org/grpc/codes"
2424
"google.golang.org/grpc/status"
25+
"k8s.io/klog/v2"
2526
)
2627

2728
type identityServer struct {
2829
d *Driver
2930
}
3031

3132
func (ids *identityServer) GetPluginInfo(ctx context.Context, req *csi.GetPluginInfoRequest) (*csi.GetPluginInfoResponse, error) {
33+
klog.V(5).Infof("Using default GetPluginInfo")
34+
3235
if ids.d.name == "" {
3336
return nil, status.Error(codes.Unavailable, "Driver name not configured")
3437
}
3538

39+
if ids.d.fqVersion == "" {
40+
return nil, status.Error(codes.Unavailable, "Driver is missing version")
41+
}
42+
3643
return &csi.GetPluginInfoResponse{
3744
Name: ids.d.name,
3845
VendorVersion: ids.d.fqVersion,
@@ -50,6 +57,7 @@ func (ids *identityServer) Probe(ctx context.Context, req *csi.ProbeRequest) (*c
5057
}
5158

5259
func (ids *identityServer) GetPluginCapabilities(ctx context.Context, req *csi.GetPluginCapabilitiesRequest) (*csi.GetPluginCapabilitiesResponse, error) {
60+
klog.V(5).Infof("GetPluginCapabilities called with req %+v", req)
5361
caps := []*csi.PluginCapability{
5462
{
5563
Type: &csi.PluginCapability_Service_{

0 commit comments

Comments
 (0)