Skip to content

Commit

Permalink
✨ fix: compilerIncompatibleAssign
Browse files Browse the repository at this point in the history
Cannot use corev1.ResourceRequirements{…} (value of type "k8s.io/api/core/v1".ResourceRequirements) as "k8s.io/api/core/v1".VolumeResourceRequirements value in struct literal
  • Loading branch information
buu-nguyen committed Dec 19, 2024
1 parent 5a9a361 commit dabbddb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions pkg/common/utils/resource/pod_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ func Test_NewPodTemplateSpecWithCommonSpec(t *testing.T) {
"namespace": "default",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("200Gi"),
},
Expand All @@ -98,7 +98,7 @@ func Test_NewPodTemplateSpecWithCommonSpec(t *testing.T) {
"namespace": "default",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("200Gi"),
},
Expand Down
12 changes: 6 additions & 6 deletions pkg/common/utils/resource/resource_common_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ var dcr = &v1.DorisCluster{
"component": "fe",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("100Gi"),
},
Expand All @@ -80,7 +80,7 @@ var dcr = &v1.DorisCluster{
"component": "fe",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("100Gi"),
},
Expand Down Expand Up @@ -110,7 +110,7 @@ var dcr = &v1.DorisCluster{
"component": "be",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("200Gi"),
},
Expand All @@ -125,7 +125,7 @@ var dcr = &v1.DorisCluster{
"component": "be",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("100Gi"),
},
Expand All @@ -151,7 +151,7 @@ var dcr = &v1.DorisCluster{
"component": "be",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("100Gi"),
},
Expand All @@ -166,7 +166,7 @@ var dcr = &v1.DorisCluster{
"component": "be",
},
PersistentVolumeClaimSpec: corev1.PersistentVolumeClaimSpec{
Resources: corev1.ResourceRequirements{
Resources: corev1.VolumeResourceRequirements{
Requests: map[corev1.ResourceName]kr.Quantity{
"storage": kr.MustParse("100Gi"),
},
Expand Down

0 comments on commit dabbddb

Please sign in to comment.