mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-14 02:43:36 +00:00
util: fix golint warnings in csiconfig, volid
golint warns about the following statements: ceph-csi/internal/util/csiconfig.go Line 49: warning: exported function Mons should have comment or be unexported (golint) ceph-csi/pkg/util/volid.go : Line 72: warning: exported method CSIIdentifier.ComposeCSIID should have comment or be unexported (golint) Reported-by: https://goreportcard.com/report/github.com/ceph/ceph-csi Updates: #975 Signed-off-by: Yug Gupta <ygupta@redhat.com>
This commit is contained in:
@ -52,6 +52,11 @@ type CSIIdentifier struct {
|
||||
// This maximum comes from the CSI spec on max bytes allowed in the various CSI ID fields
|
||||
const maxVolIDLen = 128
|
||||
|
||||
const (
|
||||
knownFieldSize = 64
|
||||
uuidSize = 36
|
||||
)
|
||||
|
||||
/*
|
||||
ComposeCSIID composes a CSI ID from passed in parameters.
|
||||
Version 1 of the encoding scheme is as follows,
|
||||
@ -64,11 +69,6 @@ Version 1 of the encoding scheme is as follows,
|
||||
Total of constant field lengths, including '-' field separators would hence be,
|
||||
4+1+4+1+1+16+1+36 = 64
|
||||
*/
|
||||
const (
|
||||
knownFieldSize = 64
|
||||
uuidSize = 36
|
||||
)
|
||||
|
||||
func (ci CSIIdentifier) ComposeCSIID() (string, error) {
|
||||
buf16 := make([]byte, 2)
|
||||
buf64 := make([]byte, 8)
|
||||
|
Reference in New Issue
Block a user