Skip to content

Commit 965e259

Browse files
committed
wip: Snapshot Controller startup should not LIST all volumesnapshots
1 parent c0cb7b7 commit 965e259

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cmd/snapshot-controller/main.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,9 @@ var version = "unknown"
8888
func ensureCustomResourceDefinitionsExist(client *clientset.Clientset, enableVolumeGroupSnapshots bool) error {
8989
condition := func(ctx context.Context) (bool, error) {
9090
var err error
91-
// List calls should return faster with a limit of 0.
91+
// List calls should return faster with a limit of 1.
9292
// We do not care about what is returned and just want to make sure the CRDs exist.
93-
listOptions := metav1.ListOptions{Limit: 0}
93+
listOptions := metav1.ListOptions{Limit: 1}
9494

9595
// scoping to an empty namespace makes `List` work across all namespaces
9696
_, err = client.SnapshotV1().VolumeSnapshots("").List(ctx, listOptions)

0 commit comments

Comments
 (0)