Skip to content

Commit

Permalink
fix: allows podInfo.Cluster is empty
Browse files Browse the repository at this point in the history
  • Loading branch information
dspo committed Dec 17, 2021
1 parent 153fb4b commit 4a1a1f5
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,6 @@ github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.m
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/erda-project/elastic v0.0.1-ex h1:5ajfxQ5S5YjpzFqY9LzL9hiKWCn6q/JDT4n8sNv7+pU=
github.com/erda-project/elastic v0.0.1-ex/go.mod h1:iAVsas6fcmt9pxtge1+dErMhecv+RLSXlD4rnZRJVW0=
github.com/erda-project/erda-infra v0.0.0-20211209074404-32e7888e4551 h1:ry/gKIlW3Vq2WvKIpceglsUSEhbBJ5yXq+YpRCPEujo=
github.com/erda-project/erda-infra v0.0.0-20211209074404-32e7888e4551/go.mod h1:JEXUFWDC/a97+3AgX/cL4xRlqL9vTDM+wVV3Ee5FXYI=
github.com/erda-project/erda-infra v0.0.0-20211215063333-0a41c73b8fe9 h1:B8sT5tE7O/PKettHhc7rZbX8L9J/dGn+dvoVBDz3BvE=
github.com/erda-project/erda-infra v0.0.0-20211215063333-0a41c73b8fe9/go.mod h1:JEXUFWDC/a97+3AgX/cL4xRlqL9vTDM+wVV3Ee5FXYI=
Expand Down
2 changes: 1 addition & 1 deletion modules/core-services/services/project/project.go
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,7 @@ func (p *Project) fetchPodInfo(dto *apistructs.ProjectDTO) {
if !strings.EqualFold(podInfo.Workspace, workspace) {
continue
}
if podInfo.Cluster != rc.ClusterName {
if podInfo.Cluster != rc.ClusterName && podInfo.Cluster != "" {
continue
}
rc.CPURequest += podInfo.CPURequest
Expand Down

0 comments on commit 4a1a1f5

Please sign in to comment.