Skip to content

Commit b71dcfc

Browse files
authored
fix: align DefaultBatchSize fallback with actual default (50) (#1048)
Two packages defined DefaultBatchSize with different values: resource/resource.go had 10 while aws/resources/adapter.go had 50. All AWS resources reference the adapter's 50, making the resource package's 10 a confusing inconsistency. Align the fallback to 50 so any resource that forgets to set BatchSize gets the same reasonable default.
1 parent 7d8c9c7 commit b71dcfc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

resource/resource.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import (
1313
)
1414

1515
// DefaultBatchSize is the maximum number of resources per batch
16-
const DefaultBatchSize = 10
16+
const DefaultBatchSize = 50
1717

1818
// Scope represents the cloud provider-specific scope for a resource.
1919
// For AWS: Region is set (e.g., "us-east-1" or "global" for global resources)
@@ -49,7 +49,7 @@ type Resource[C any] struct {
4949
ResourceTypeName string
5050

5151
// BatchSize is the maximum number of resources to delete per batch.
52-
// If 0, defaults to DefaultBatchSize (10).
52+
// If 0, defaults to DefaultBatchSize (50).
5353
// Set based on AWS/GCP API rate limits for this resource type.
5454
BatchSize int
5555

0 commit comments

Comments
 (0)