Skip to content

Commit

Permalink
util: rearrange struct to fix lint
Browse files Browse the repository at this point in the history
re-arrange the struct members to
fix below lint issue

```
struct of size 336 bytes could be of size 328 bytes
```

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
  • Loading branch information
Madhu-1 authored and mergify[bot] committed Nov 3, 2023
1 parent 3ea540b commit 00d6971
Showing 1 changed file with 23 additions and 24 deletions.
47 changes: 23 additions & 24 deletions internal/util/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,34 +93,20 @@ type Config struct {
PluginPath string // location of cephcsi plugin
StagingPath string // location of cephcsi staging path
DomainLabels string // list of domain labels to read from the node

// metrics related flags
MetricsPath string // path of prometheus endpoint where metrics will be available
MetricsIP string // TCP port for liveness/ metrics requests

// CSI-Addons endpoint
CSIAddonsEndpoint string

// Cluster name
ClusterName string

// mount option related flags
KernelMountOptions string // Comma separated string of mount options accepted by cephfs kernel mounter
FuseMountOptions string // Comma separated string of mount options accepted by ceph-fuse mounter

PidLimit int // PID limit to configure through cgroups")
MetricsPort int // TCP port for liveness/grpc metrics requests
PollTime time.Duration // time interval in seconds between each poll
PoolTimeout time.Duration // probe timeout in seconds

EnableProfiling bool // flag to enable profiling
IsControllerServer bool // if set to true start provisioner server
IsNodeServer bool // if set to true start node server
Version bool // cephcsi version

// SkipForceFlatten is set to false if the kernel supports mounting of
// rbd image or the image chain has the deep-flatten feature.
SkipForceFlatten bool

// cephfs related flags
ForceKernelCephFS bool // force to use the ceph kernel client even if the kernel is < 4.17

SetMetadata bool // set metadata on the volume

// RbdHardMaxCloneDepth is the hard limit for maximum number of nested volume clones that are taken before a flatten
// occurs
RbdHardMaxCloneDepth uint
Expand All @@ -139,11 +125,24 @@ type Config struct {
// reached cephcsi will start flattening the older rbd images.
MinSnapshotsOnImage uint

// CSI-Addons endpoint
CSIAddonsEndpoint string
PidLimit int // PID limit to configure through cgroups")
MetricsPort int // TCP port for liveness/grpc metrics requests
PollTime time.Duration // time interval in seconds between each poll
PoolTimeout time.Duration // probe timeout in seconds

// Cluster name
ClusterName string
EnableProfiling bool // flag to enable profiling
IsControllerServer bool // if set to true start provisioner server
IsNodeServer bool // if set to true start node server
Version bool // cephcsi version

// SkipForceFlatten is set to false if the kernel supports mounting of
// rbd image or the image chain has the deep-flatten feature.
SkipForceFlatten bool

// cephfs related flags
ForceKernelCephFS bool // force to use the ceph kernel client even if the kernel is < 4.17

SetMetadata bool // set metadata on the volume

// Read affinity related options
EnableReadAffinity bool // enable OSD read affinity.
Expand Down

0 comments on commit 00d6971

Please sign in to comment.