mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-14 02:43:36 +00:00
util: log repication RequestID
currently we are not logging the RequestID for the replication RPC calls. This PR adds the replication case to the getReqID function. Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
committed by
mergify[bot]
parent
492e43639c
commit
4e296bf65e
@ -24,6 +24,7 @@ import (
|
||||
"testing"
|
||||
|
||||
"github.com/container-storage-interface/spec/lib/go/csi"
|
||||
"github.com/csi-addons/spec/lib/go/replication"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
mount "k8s.io/mount-utils"
|
||||
@ -75,6 +76,25 @@ func TestGetReqID(t *testing.T) {
|
||||
&csi.GetVolumeGroupSnapshotRequest{
|
||||
GroupSnapshotId: fakeID,
|
||||
},
|
||||
|
||||
&replication.EnableVolumeReplicationRequest{
|
||||
VolumeId: fakeID,
|
||||
},
|
||||
&replication.DisableVolumeReplicationRequest{
|
||||
VolumeId: fakeID,
|
||||
},
|
||||
&replication.PromoteVolumeRequest{
|
||||
VolumeId: fakeID,
|
||||
},
|
||||
&replication.DemoteVolumeRequest{
|
||||
VolumeId: fakeID,
|
||||
},
|
||||
&replication.ResyncVolumeRequest{
|
||||
VolumeId: fakeID,
|
||||
},
|
||||
&replication.GetVolumeReplicationInfoRequest{
|
||||
VolumeId: fakeID,
|
||||
},
|
||||
}
|
||||
for _, r := range req {
|
||||
if got := getReqID(r); got != fakeID {
|
||||
|
Reference in New Issue
Block a user