From 632e10a4e0051b580fc20d65f79a80a9da8b028e Mon Sep 17 00:00:00 2001 From: David van der Spek Date: Fri, 14 Jul 2023 14:04:04 +0200 Subject: [PATCH] fix: dimension mappings types Signed-off-by: David van der Spek --- api/observability/v1alpha1/tempo_limit_types.go | 2 +- api/observability/v1alpha1/zz_generated.deepcopy.go | 10 ++-------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/api/observability/v1alpha1/tempo_limit_types.go b/api/observability/v1alpha1/tempo_limit_types.go index b86e34e..212c69e 100644 --- a/api/observability/v1alpha1/tempo_limit_types.go +++ b/api/observability/v1alpha1/tempo_limit_types.go @@ -238,7 +238,7 @@ type DimensionMappings struct { // +kubebuilder:validation:Optional Name *string `yaml:"name,omitempty" json:"name,omitempty"` // +kubebuilder:validation:Optional - SourceLabel []*string `yaml:"source_labels,omitempty" json:"source_labels,omitempty"` + SourceLabel []string `yaml:"source_labels,omitempty" json:"source_labels,omitempty"` // +kubebuilder:validation:Optional Join *string `yaml:"join,omitempty" json:"join,omitempty"` } diff --git a/api/observability/v1alpha1/zz_generated.deepcopy.go b/api/observability/v1alpha1/zz_generated.deepcopy.go index ec2482d..b4ac567 100644 --- a/api/observability/v1alpha1/zz_generated.deepcopy.go +++ b/api/observability/v1alpha1/zz_generated.deepcopy.go @@ -211,14 +211,8 @@ func (in *DimensionMappings) DeepCopyInto(out *DimensionMappings) { } if in.SourceLabel != nil { in, out := &in.SourceLabel, &out.SourceLabel - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } + *out = make([]string, len(*in)) + copy(*out, *in) } if in.Join != nil { in, out := &in.Join, &out.Join