Skip to content

Commit

Permalink
comments resolved
Browse files Browse the repository at this point in the history
Signed-off-by: sayedppqq <[email protected]>
  • Loading branch information
sayedppqq committed Nov 15, 2024
1 parent fa97422 commit c5bd380
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions apis/kubedb/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -1607,10 +1607,10 @@ var (
core.ResourceStorage: resource.MustParse("2Gi"),
// these are the default cpu & memory for a coordinator container
core.ResourceCPU: resource.MustParse(".200"),
core.ResourceMemory: resource.MustParse("250Mi"),
core.ResourceMemory: resource.MustParse("256Mi"),
},
Limits: core.ResourceList{
core.ResourceMemory: resource.MustParse("250Mi"),
core.ResourceMemory: resource.MustParse("256Mi"),
},
}
DefaultArbiterMemoryIntensive = core.ResourceRequirements{
Expand All @@ -1624,8 +1624,8 @@ var (
},
}

// DefaultResourcesCPUIntensiveVersion6 is for MongoDB versions >= 6
DefaultResourcesCPUIntensiveVersion6 = core.ResourceRequirements{
// DefaultResourcesCPUIntensiveMongoDBv6 is for MongoDB versions >= 6
DefaultResourcesCPUIntensiveMongoDBv6 = core.ResourceRequirements{
Requests: core.ResourceList{
core.ResourceCPU: resource.MustParse(".800"),
core.ResourceMemory: resource.MustParse("1024Mi"),
Expand All @@ -1634,8 +1634,8 @@ var (
core.ResourceMemory: resource.MustParse("1024Mi"),
},
}
// DefaultResourcesCPUIntensiveVersion8 is for MongoDB versions >= 8
DefaultResourcesCPUIntensiveVersion8 = core.ResourceRequirements{
// DefaultResourcesCPUIntensiveMongoDBv8 is for MongoDB versions >= 8
DefaultResourcesCPUIntensiveMongoDBv8 = core.ResourceRequirements{
Requests: core.ResourceList{
core.ResourceCPU: resource.MustParse(".800"),
core.ResourceMemory: resource.MustParse("1.5Gi"),
Expand Down
4 changes: 2 additions & 2 deletions apis/kubedb/v1/mongodb_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -714,9 +714,9 @@ func (m *MongoDB) setPodTemplateDefaultValues(podTemplate *ofstv2.PodTemplateSpe

defaultResource := kubedb.DefaultResources
if m.isLaterVersion(mgVersion, 8) {
defaultResource = kubedb.DefaultResourcesCPUIntensiveVersion8
defaultResource = kubedb.DefaultResourcesCPUIntensiveMongoDBv8
} else if m.isLaterVersion(mgVersion, 6) {
defaultResource = kubedb.DefaultResourcesCPUIntensiveVersion6
defaultResource = kubedb.DefaultResourcesCPUIntensiveMongoDBv6
}

container := ofst_util.EnsureInitContainerExists(podTemplate, kubedb.MongoDBInitInstallContainerName)
Expand Down

0 comments on commit c5bd380

Please sign in to comment.